Skip to content

Instantly share code, notes, and snippets.

@SjB
Last active September 8, 2015 18:32
Show Gist options
  • Save SjB/39c3d41b3e61906c837c to your computer and use it in GitHub Desktop.
Save SjB/39c3d41b3e61906c837c to your computer and use it in GitHub Desktop.
Windows csharp build script
@echo Off
setlocal
set NUGETURL="http://nuget.org/nuget.exe"
set TOOLSDIR=tools
set NUGET=%TOOLSDIR%\NuGet.exe
set CAKE=%TOOLSDIR%\Cake\Cake.exe
IF NOT EXIST %TOOLSDIR% mkdir %TOOLSDIR%
IF NOT EXIST %NUGET% (
powershell -Command "(new-object System.Net.WebClient).DownloadFile(\"%NUGETURL%\", \"%NUGET%\");"
)
IF NOT EXIST %CAKE% (
%NUGET% install Cake -OutputDirectory Tools -ExcludeVersion
)
%CAKE% build.cake %*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment