forked from DotNet4Neo4j/Neo4jClient
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.bat
48 lines (37 loc) · 1.34 KB
/
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
38
39
40
41
42
43
44
45
46
47
48
REM MyGet Build Commands
@echo Off
set config=%1
if "%config%" == "" (
set config=Release
)
set version=-Version 1.0.0
if not "%PackageVersion%" == "" (
set version=-Version %PackageVersion%
)
REM Restore packages
tools\nuget.exe restore Neo4jClient.sln
if not "%errorlevel%"=="0" goto failure
@echo Packages restored - on to build...
REM Build
"%programfiles(x86)%\MSBuild\14.0\Bin\MSBuild.exe" Neo4jClient.sln /p:Configuration="%config%" /m /v:M /fl /flp:LogFile=msbuild.log;Verbosity=Normal /nr:false
if not "%errorlevel%"=="0" goto failure
@echo Built and onto tests....
REM XUnit tests
tools\nuget.exe install xunit.runner.console -Version 2.2.0 -OutputDirectory packages
if not "%errorlevel%"=="0" goto failure
@echo XUnit installed...
packages\xunit.runner.console.2.2.0\tools\xunit.console.x86.exe Neo4jClient.Tests\bin\%config%\Neo4jClient.Tests.dll
if not "%errorlevel%"=="0" goto failure
@echo Neo4jClient tests... SUCCESS.
packages\xunit.runner.console.2.2.0\tools\xunit.console.x86.exe Neo4jClient.Vb.Tests\bin\%config%\Neo4jClient.Vb.Tests.dll
if not "%errorlevel%"=="0" goto failure
@echo Neo4jClient VB tests... SUCCESS.
REM Package
mkdir Artifacts
tools\nuget.exe pack "Neo4jClient.nuspec" -o Artifacts -p Configuration=%config% %version%
if not "%errorlevel%"=="0" goto failure
@echo Packed and ready to roll!
:success
exit 0
:failure
exit -1