-
Notifications
You must be signed in to change notification settings - Fork 9
/
appveyor.yml
58 lines (58 loc) · 3.32 KB
/
appveyor.yml
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
49
50
51
52
53
54
55
56
57
58
version: '1.0.0-{build}'
configuration:
- Release
platform: Any CPU
environment:
# Don't report back to the mothership
DOTNET_CLI_TELEMETRY_OPTOUT: 1
COVERALLS_REPO_TOKEN:
secure:ZOotByGmB2CHvWqjjKkuBJd9g2akvEajO87x4kW1cTVjUYHPQv9KmHa9+YRCnIHU
CODECOV_TOKEN:
secure: ycGY4b36w5tfqg4/uuKUTltDs6kN19q4VqAguuRBW4B/bGbdlalu4kwj9FYVwjB2
pull_requests:
do_not_increment_build_number: true
init:
- ps: $Env:LABEL = "pre-${Env:APPVEYOR_BUILD_NUMBER}"
before_build:
- appveyor-retry dotnet restore -v Minimal
build_script:
- dotnet build "src\RService.IO" -c %CONFIGURATION%
- dotnet build "src\RService.IO.Abstractions" -c %CONFIGURATION%
- dotnet build "src\RService.IO.Authorization" -c %CONFIGURATION%
test_script:
- ps: '& ${env:homedrive}${env:homepath}\.nuget\packages\OpenCover\4.6.519\tools\OpenCover.Console.exe "-target:C:\Program Files\dotnet\dotnet.exe" -targetargs:"test .\test\RService.IO.Tests\RService.IO.Tests.csproj" -register:user -filter:"+[RService.IO*]* -[RService.IO.Tests*]*" -output:coverage.xml -oldStyle'
- ps: '& ${env:homedrive}${env:homepath}\.nuget\packages\OpenCover\4.6.519\tools\OpenCover.Console.exe "-target:C:\Program Files\dotnet\dotnet.exe" -targetargs:"test .\test\RService.IO.Authorization.Tests\RService.IO.Authorization.Tests.csproj" -register:user -filter:"+[RService.IO*]* -[RService.IO.Authorization.Tests*]*" -mergeoutput -output:coverage.xml -oldStyle'
- ps: '& ${env:homedrive}${env:homepath}\.nuget\packages\OpenCover\4.6.519\tools\OpenCover.Console.exe "-target:C:\Program Files\dotnet\dotnet.exe" -targetargs:"test .\test\RService.IO.Tests.Integration\RService.IO.Tests.Integration.csproj" -register:user -filter:"+[RService.IO*]* -[RService.IO.Tests*]*" -mergeoutput -output:coverage.xml -oldStyle'
- ps: '& ${env:homedrive}${env:homepath}\.nuget\packages\coveralls.io\1.3.4\tools\coveralls.net.exe --opencover coverage.xml'
- ps: pip install codecov; codecov -f coverage.xml -X gcov
after_test:
- ps: |
if ($env:APPVEYOR_REPO_BRANCH -eq "master")
{
echo "building master release"
dotnet pack .\src\RService.IO.Abstractions\RService.IO.Abstractions.csproj -c ${env:CONFIGURATION} -o artifacts
dotnet pack .\src\RService.IO\RService.IO.csproj -c ${env:CONFIGURATION} -o artifacts
dotnet pack .\src\RService.IO.Authorization\RService.IO.Authorization.csproj -c ${env:CONFIGURATION} -o artifacts
}
else
{
echo "build ${env:LABEL}"
dotnet pack .\src\RService.IO.Abstractions\RService.IO.Abstractions.csproj -c ${env:CONFIGURATION} -o artifacts --version-suffix "pre-${env:APPVEYOR_BUILD_NUMBER}"
dotnet pack .\src\RService.IO\RService.IO.csproj -c ${env:CONFIGURATION} -o artifacts --version-suffix "pre-${env:APPVEYOR_BUILD_NUMBER}"
dotnet pack .\src\RService.IO.Authorization\RService.IO.Authorization.csproj -c ${env:CONFIGURATION} -o artifacts --version-suffix "pre-${env:APPVEYOR_BUILD_NUMBER}"
}
artifacts:
- path: '**/RService.IO.*.nupkg'
name: NuGet Package
deploy:
- provider: NuGet
api_key:
secure: TafSc421VlrLm7iCk6Xm2/ss0aZT8EXfcU2DEarrIeoWxg+NxXH8apUKAV+oT8Kp
skip_symbols: false
artifact: /.*\.nupkg/
on:
branch: master
configuration: Release
appveyor_repo_tag: true
#cache:
#- '%USERPROFILE%\.nuget\packages'