forked from ValveResourceFormat/ValveResourceFormat
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathappveyor.yml
56 lines (46 loc) · 2.26 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
version: 0.0.17.{build}
image: Visual Studio 2019
assembly_info:
patch: true
file: '**\AssemblyInfo.*'
assembly_version: '{version}'
assembly_file_version: '{version}'
assembly_informational_version: '{version}'
environment:
COVERALLS_REPO_TOKEN:
secure: WBUIkucQ46pEHPX6LbgX1WhSEKb8E7kdl7SMJjfMn+CxUvr/oij9IKuJlSLDBT0p
cache: '%LocalAppData%\NuGet\Cache'
build_script:
- msbuild /t:Restore /t:Build /p:Configuration=Release
after_build:
- dotnet pack --configuration release ValveResourceFormat\ValveResourceFormat.csproj
- dotnet publish --configuration Release -p:PublishSingleFile=true --runtime win-x64 Decompiler\Decompiler.csproj
- dotnet publish --configuration Release -p:PublishSingleFile=true --runtime linux-x64 Decompiler\Decompiler.csproj
test_script:
- ps: >-
$opencover = (Resolve-Path "$ENV:USERPROFILE/.nuget/packages/OpenCover/*/tools/OpenCover.Console.exe").ToString();
& $opencover "-target:%ProgramFiles%\dotnet\dotnet.exe" "-targetargs:test -c debug Tests\Tests.csproj" -filter:"+[ValveResourceFormat*]* -[ValveResourceFormat]SevenZip*" -output:opencoverCoverage.xml -register:administrator -returntargetcode -oldStyle
if ($LastExitCode -ne 0) {
throw "Exec: $ErrorMessage`nExit code: $LastExitCode";
}
if ($env:APPVEYOR_PULL_REQUEST_NUMBER -eq $null) {
$coveralls = (Resolve-Path "$ENV:USERPROFILE/.nuget/packages/coveralls.net/*/tools/csmacnz.coveralls.exe").ToString();
& $coveralls --opencover -i opencoverCoverage.xml --repoToken $env:COVERALLS_REPO_TOKEN --commitId $env:APPVEYOR_REPO_COMMIT --commitBranch $env:APPVEYOR_REPO_BRANCH --commitAuthor $env:APPVEYOR_REPO_COMMIT_AUTHOR --commitEmail $env:APPVEYOR_REPO_COMMIT_AUTHOR_EMAIL --commitMessage $env:APPVEYOR_REPO_COMMIT_MESSAGE --jobId $env:APPVEYOR_BUILD_NUMBER --serviceName appveyor
}
artifacts:
- path: Decompiler\bin\Release\netcoreapp3.1\win-x64\publish
name: Decompiler-win-x64
- path: Decompiler\bin\Release\netcoreapp3.1\linux-x64\publish
name: Decompiler-linux-x64
- path: GUI\bin\Release
name: GUI
- path: '**\*.nupkg'
name: ValveResourceFormat
deploy:
- provider: GitHub
auth_token:
secure: nK1ZJwyjxiXhpKYZ8AjsgEqtvTYJR9A4hc5KDseSNi/CO+9scXnuc1A/ZODoAja4
draft: false
prerelease: true
on:
APPVEYOR_REPO_TAG: true