File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -36,13 +36,11 @@ function detect_platform_and_runtime_id ()
36
36
fi
37
37
}
38
38
39
- SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " && pwd ) "
39
+ SCRIPT_DIR=$1
40
40
pushd " $SCRIPT_DIR "
41
41
source " $SCRIPT_DIR /Misc/helpers.sh"
42
-
43
- DOTNETSDK_ROOT=" $SCRIPT_DIR /_dotnetsdk"
44
- DOTNETSDK_VERSION=" 8.0.100"
45
- DOTNETSDK_INSTALLDIR=" $DOTNETSDK_ROOT /$DOTNETSDK_VERSION "
42
+ DOTNETSDK_INSTALLDIR=$2
43
+ DOTNETSDK_VERSION=$3
46
44
47
45
detect_platform_and_runtime_id
48
46
echo " Current platform: $CURRENT_PLATFORM "
@@ -63,10 +61,8 @@ if [[ (! -d "${DOTNETSDK_INSTALLDIR}") || (! -e "${DOTNETSDK_INSTALLDIR}/.${DOTN
63
61
# run dotnet-install.ps1 on windows, dotnet-install.sh on linux
64
62
if [[ (" $CURRENT_PLATFORM " == " windows" ) ]]; then
65
63
echo " Convert ${DOTNETSDK_INSTALLDIR} to Windows style path"
66
- sdkinstallwindow_path=${DOTNETSDK_INSTALLDIR: 1}
67
- sdkinstallwindow_path=${sdkinstallwindow_path: 0: 1} :${sdkinstallwindow_path: 1}
68
64
architecture=$( echo $DETECTED_RUNTIME_ID | cut -d " -" -f2)
69
- powershell -NoLogo -Sta -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command " & \" ./Misc/dotnet-install.ps1\" -Version ${DOTNETSDK_VERSION} -InstallDir \" ${sdkinstallwindow_path } \" -Architecture ${architecture} -NoPath; exit \$ LastExitCode;" || checkRC dotnet-install.ps1
65
+ powershell -NoLogo -Sta -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -Command " & \" ./Misc/dotnet-install.ps1\" -Version ${DOTNETSDK_VERSION} -InstallDir \" ${DOTNETSDK_INSTALLDIR } \" -Architecture ${architecture} -NoPath; exit \$ LastExitCode;" || checkRC dotnet-install.ps1
70
66
else
71
67
bash ./Misc/dotnet-install.sh --version ${DOTNETSDK_VERSION} --install-dir " ${DOTNETSDK_INSTALLDIR} " --no-path || checkRC dotnet-install.sh
72
68
fi
Original file line number Diff line number Diff line change @@ -1773,8 +1773,12 @@ var ensureBuildConfigGeneratorPrereqs = function (baseConfigToolPath) {
1773
1773
configToolBuildUtility = path . join ( baseConfigToolPath , "dev.sh" ) ;
1774
1774
}
1775
1775
1776
+ const dotnetSdkVersion = "8.0.100" ;
1777
+ const dotnetInstallationDirectory = path . resolve ( baseConfigToolPath , "_dotnetsdk" , dotnetSdkVersion ) ;
1778
+
1776
1779
// build configToolBuildUtility if needed. (up-to-date check will skip build if not needed)
1777
- run ( configToolBuildUtility , true ) ;
1780
+ run ( `${ configToolBuildUtility } ${ baseConfigToolPath } ${ dotnetInstallationDirectory } ${ dotnetSdkVersion } ` , true ) ;
1781
+ addPath ( dotnetInstallationDirectory ) ;
1778
1782
} ;
1779
1783
exports . ensureBuildConfigGeneratorPrereqs = ensureBuildConfigGeneratorPrereqs ;
1780
1784
You can’t perform that action at this time.
0 commit comments