forked from EasyNetQ/EasyNetQ
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.bat
executable file
·37 lines (26 loc) · 947 Bytes
/
build.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
@echo off
setlocal EnableDelayedExpansion
set ScriptRoot=%~dp0
set VisualStudioInstallation=%ProgramFiles(x86)%\Microsoft Visual Studio\2017
echo Searching for Visual Studio in: "%VisualStudioInstallation%"
if defined DevEnvDir (
echo Visual Studio 2017 development environment has already been set.
) else (
echo Setting Visual Studio 2017 environment...
for /F %%G in ('dir /b "%VisualStudioInstallation%"') do (
set VisualStudioCommonTools=!VisualStudioInstallation!\%%G\Common7\Tools\VsDevCmd.bat
if exist "!VisualStudioCommonTools!" (
call "!VisualStudioCommonTools!"
goto :RunBuild
) else (
echo ERROR: Could not locate "!VisualStudioCommonTools!". Trying next installation...
)
)
)
:RunBuild
if not defined DevEnvDir (
echo Visual Studio 2017 environment should have been set.
exit /b 1
)
msbuild %ScriptRoot%\Build\EasyNetQ.proj
pause