mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-06-28 15:34:39 +08:00
Making ClickToBuild compatible with VS 2019
This commit is contained in:
parent
c9ae8fa6b6
commit
0a82721968
@ -3,7 +3,7 @@
|
|||||||
REM Necessary for the InstallDir variable to work inside the MsBuild-finding loop below.
|
REM Necessary for the InstallDir variable to work inside the MsBuild-finding loop below.
|
||||||
SETLOCAL ENABLEDELAYEDEXPANSION
|
SETLOCAL ENABLEDELAYEDEXPANSION
|
||||||
|
|
||||||
for /f "usebackq tokens=1* delims=: " %%i in (`lib\vswhere\vswhere -latest -version "[15.0,16.0)" -requires Microsoft.Component.MSBuild`) do (
|
for /f "usebackq tokens=1* delims=: " %%i in (`lib\vswhere\vswhere -latest -version "[15.0,17.0)" -requires Microsoft.Component.MSBuild`) do (
|
||||||
if /i "%%i"=="installationPath" (
|
if /i "%%i"=="installationPath" (
|
||||||
set InstallDir=%%j
|
set InstallDir=%%j
|
||||||
echo !InstallDir!
|
echo !InstallDir!
|
||||||
@ -12,6 +12,11 @@ for /f "usebackq tokens=1* delims=: " %%i in (`lib\vswhere\vswhere -latest -vers
|
|||||||
set msbuild="!InstallDir!\MSBuild\15.0\Bin\MSBuild.exe"
|
set msbuild="!InstallDir!\MSBuild\15.0\Bin\MSBuild.exe"
|
||||||
goto build
|
goto build
|
||||||
)
|
)
|
||||||
|
if exist "!InstallDir!\MSBuild\Current\Bin\MSBuild.exe" (
|
||||||
|
echo "Using MSBuild from Visual Studio 2019"
|
||||||
|
set msbuild="!InstallDir!\MSBuild\Current\Bin\MSBuild.exe"
|
||||||
|
goto build
|
||||||
|
)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user