mirror of
https://github.com/actions/setup-dotnet.git
synced 2025-08-20 23:50:19 +00:00
Change DOTNET_ROOT for Linux
This commit is contained in:
parent
813933aedb
commit
fd4ddcf785
4
dist/index.js
vendored
4
dist/index.js
vendored
@ -344,9 +344,11 @@ class DotnetCoreInstaller {
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (IS_WINDOWS) {
|
if (IS_WINDOWS) {
|
||||||
// This is the default set in install-dotnet.ps1
|
|
||||||
core.exportVariable('DOTNET_ROOT', DotnetCoreInstaller.installationDirectoryWindows);
|
core.exportVariable('DOTNET_ROOT', DotnetCoreInstaller.installationDirectoryWindows);
|
||||||
}
|
}
|
||||||
|
else if (IS_LINUX) {
|
||||||
|
core.exportVariable('DOTNET_ROOT', DotnetCoreInstaller.installationDirectoryLinux);
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
// This is the default set in install-dotnet.sh
|
// This is the default set in install-dotnet.sh
|
||||||
core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
|
core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
|
||||||
|
@ -204,11 +204,16 @@ export class DotnetCoreInstaller {
|
|||||||
core.exportVariable('DOTNET_ROOT', process.env['DOTNET_INSTALL_DIR']);
|
core.exportVariable('DOTNET_ROOT', process.env['DOTNET_INSTALL_DIR']);
|
||||||
} else {
|
} else {
|
||||||
if (IS_WINDOWS) {
|
if (IS_WINDOWS) {
|
||||||
// This is the default set in install-dotnet.ps1
|
|
||||||
core.exportVariable(
|
core.exportVariable(
|
||||||
'DOTNET_ROOT',
|
'DOTNET_ROOT',
|
||||||
DotnetCoreInstaller.installationDirectoryWindows
|
DotnetCoreInstaller.installationDirectoryWindows
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
else if (IS_LINUX) {
|
||||||
|
core.exportVariable(
|
||||||
|
'DOTNET_ROOT',
|
||||||
|
DotnetCoreInstaller.installationDirectoryLinux
|
||||||
|
);
|
||||||
} else {
|
} else {
|
||||||
// This is the default set in install-dotnet.sh
|
// This is the default set in install-dotnet.sh
|
||||||
core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
|
core.addPath(path.join(process.env['HOME'] + '', '.dotnet'));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user