-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathbuild.cmd
More file actions
35 lines (26 loc) · 681 Bytes
/
build.cmd
File metadata and controls
35 lines (26 loc) · 681 Bytes
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
@echo off
setlocal
set _projectName=OutputColorizer
set _solution=%_projectName%.sln
set _codeProject=src\%_projectName%.csproj
set _testProject=test\%_projectName%.tests.csproj
set _config=%1
if not defined _config (
set _config=Debug
)
echo Building Config '%_config%'
echo Solution: '%_solution%'
echo Code: '%_codeProject%'
echo Test: '%_testProject%'
echo Restoring packages
dotnet restore
echo Cleaning solution
dotnet clean %_solution%
echo Building solution
dotnet build %_solution% -c %_config%
echo Running tests
dotnet test --no-build -c %_config% %_testProject%
echo Creating NuGet package
dotnet pack --no-build -c %_config% %_codeProject%
endlocal
@echo on