From 29b331e164c93306aff7ad8596db81b9da6292ad Mon Sep 17 00:00:00 2001 From: Congyong Su Date: Fri, 16 Oct 2015 14:24:54 +0800 Subject: [PATCH] Build Restier nuget packages build.cmd works with vs2015. version: 0.3 beta-3 --- BuildNuGets.cmd | 30 +++++++++++++++++++ build.cmd | 3 ++ src/CommonAssemblyInfo.cs | 2 +- .../Microsoft.Restier.nuspec | 9 +++--- 4 files changed, 38 insertions(+), 6 deletions(-) create mode 100644 BuildNuGets.cmd diff --git a/BuildNuGets.cmd b/BuildNuGets.cmd new file mode 100644 index 00000000..d5c26079 --- /dev/null +++ b/BuildNuGets.cmd @@ -0,0 +1,30 @@ +@ECHO OFF +pushd %~dp0 +setlocal + +if exist .nuget\nuget.exe goto Prepare +echo Downloading Nuget.exe +call build.cmd DownloadNuGet >NUL + +:Prepare +if exist bin\nuget goto Configure +md bin\nuget + +:Configure +set config=%1 +if not defined config set config=Debug + +if exist bin\nuget\%config% goto Build +md bin\nuget\%config% + +:Build +set params=-Prop Configuration=%config% -OutputDirectory bin\nuget\%config% + +.nuget\NuGet pack src\Microsoft.Restier.Core\Microsoft.Restier.Core.csproj %params% +.nuget\NuGet pack src\Microsoft.Restier.Security\Microsoft.Restier.Security.csproj %params% +.nuget\NuGet pack src\Microsoft.Restier.EntityFramework\Microsoft.Restier.EntityFramework.csproj %params% +.nuget\NuGet pack src\Microsoft.Restier.WebApi\Microsoft.Restier.WebApi.csproj %params% +.nuget\NuGet pack src\Microsoft.Restier\Microsoft.Restier.nuspec %params% + +popd +endlocal \ No newline at end of file diff --git a/build.cmd b/build.cmd index a3ce0cd1..732903d3 100644 --- a/build.cmd +++ b/build.cmd @@ -12,6 +12,9 @@ REM is not supported. Also handle x86 operating systems, where %ProgramFiles(x86 REM %MSBuild% value when setting the variable and never quote %MSBuild% references. set MSBuild="%ProgramFiles(x86)%\MSBuild\12.0\Bin\MSBuild.exe" if not exist %MSBuild% @set MSBuild="%ProgramFiles%\MSBuild\12.0\Bin\MSBuild.exe" +REM Check for VS2015 +if not exist %MSBuild% @set MSBuild="%ProgramFiles(x86)%\MSBuild\14.0\Bin\MSBuild.exe" +if not exist %MSBuild% @set MSBuild="%ProgramFiles%\MSBuild\14.0\Bin\MSBuild.exe" if "%1" == "" goto BuildDefaults diff --git a/src/CommonAssemblyInfo.cs b/src/CommonAssemblyInfo.cs index 9575da94..5b13d61a 100644 --- a/src/CommonAssemblyInfo.cs +++ b/src/CommonAssemblyInfo.cs @@ -12,5 +12,5 @@ [assembly: AssemblyVersion("0.3.0.0")] [assembly: AssemblyFileVersion("0.3.0.0")] -[assembly: AssemblyInformationalVersion("0.3.0-beta2")] +[assembly: AssemblyInformationalVersion("0.3.0-beta3")] [assembly: AssemblyMetadata("Serviceable", "True")] \ No newline at end of file diff --git a/src/Microsoft.Restier/Microsoft.Restier.nuspec b/src/Microsoft.Restier/Microsoft.Restier.nuspec index e51d174c..33a2385b 100644 --- a/src/Microsoft.Restier/Microsoft.Restier.nuspec +++ b/src/Microsoft.Restier/Microsoft.Restier.nuspec @@ -2,7 +2,7 @@ Microsoft.Restier - 0.3.0-beta2 + 0.3.0-beta3 RESTier Microsoft Microsoft @@ -11,10 +11,9 @@ true - - - - + + + \ No newline at end of file