forked from jgoz/muster
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpackage.cmd
More file actions
34 lines (24 loc) · 1.13 KB
/
package.cmd
File metadata and controls
34 lines (24 loc) · 1.13 KB
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
@echo off
set NUGET_EXE=bin\nuget-bin\nuget.exe
set NUGET_BOOTSTRAPPER_EXE=bin\nuget-bin\nuget-bootstrap.exe
if exist %NUGET_EXE% goto package
%NUGET_BOOTSTRAPPER_EXE%
move %NUGET_BOOTSTRAPPER_EXE% %NUGET_EXE%
move %NUGET_BOOTSTRAPPER_EXE%.old %NUGET_BOOTSTRAPPER_EXE%
:package
set /p VERSION=Enter version (e.g. 1.0):
set /p BUILD=Enter a build (e.g. 11234):
set /p REVISION=Enter a revision (e.g. 7):
set /p MATURITY=Enter maturity (e.g. Alpha, Beta, RC, Release, etc.):
echo using System.Reflection; > "src/VersionAssemblyInfo.cs"
echo. >> "src/VersionAssemblyInfo.cs"
echo [assembly: AssemblyVersion("%VERSION%.0.0")] >> "src/VersionAssemblyInfo.cs"
echo [assembly: AssemblyFileVersion("%VERSION%.%BUILD%.%REVISION%")] >> "src/VersionAssemblyInfo.cs"
echo //// [assembly: AssemblyInformationalVersion("%VERSION%.%BUILD%.%REVISION% %MATURITY%")] >> "src/VersionAssemblyInfo.cs"
if exist package ( rmdir /s /q package )
mkdir package
call build.cmd
%NUGET_EXE% Pack muster.nuspec -Version %VERSION%.%REVISION% -OutputDirectory package -Symbols
rmdir /s /q publish-v4.0
:done
if errorlevel 1 pause else exit