Last active
December 17, 2015 14:49
-
-
Save deejaygraham/5627119 to your computer and use it in GitHub Desktop.
Example batch invoke of MsBuild project file with verbosity and target. Needs to check for x64/x86 paths.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
rem Assume x86 to start with | |
SET MsBuildPath="%windir%\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe" | |
rem Is this a 64 bit machine? | |
IF EXIST "%Programfiles(x86)%" SET MsBuildPath="%windir%\Microsoft.NET\Framework64\v4.0.30319\MSBuild.exe" | |
if "%1" == "" goto DefaultTarget | |
goto SpecificTarget | |
:DefaultTarget | |
%MsBuildPath% Test.proj /verbosity:detailed | |
goto End | |
:SpecificTarget | |
%MsBuildPath% Test.proj /t:%* | |
:End |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment