OSDN Git Service

バージョン v2.5.1-dev 開発開始
[opentween/open-tween.git] / appveyor.yml
1 version: 2.5.0.{build}
2
3 os: Visual Studio 2019
4
5 environment:
6   matrix:
7     - RELEASE_TAG: 'false'
8     - RELEASE_TAG: 'true'
9
10 configuration:
11   - Debug
12   - Release
13
14 matrix:
15   exclude:
16     - RELEASE_TAG: 'false'
17       configuration: Release
18     - RELEASE_TAG: 'true'
19       configuration: Debug
20
21 for:
22   - # for dev build
23     matrix:
24       only:
25         - RELEASE_TAG: 'false'
26     skip_tags: true
27     assembly_info:
28       patch: true
29       file: OpenTween\Properties\AssemblyInfo.cs
30       assembly_version: '{version}'
31     artifacts:
32       - name: OpenTween.zip
33         path: OpenTween_dev-$(APPVEYOR_BUILD_NUMBER).zip
34   - # for release build
35     matrix:
36       only:
37         - RELEASE_TAG: 'true'
38     skip_non_tags: true
39     artifacts:
40       - name: OpenTween.zip
41         path: $(APPVEYOR_REPO_TAG_NAME).zip
42
43 build:
44   project: OpenTween.sln
45   verbosity: minimal
46
47 cache:
48   - ./packages/
49
50 init:
51   - git config --global core.autocrlf true
52
53 before_build:
54   - nuget restore
55   - choco install opencover.portable
56
57 test_script:
58   - OpenCover.Console.exe -register -target:"%xunit20%\xunit.console.exe" -targetargs:".\OpenTween.Tests\bin\%CONFIGURATION%\net472\OpenTween.Tests.dll -noshadow -appveyor" -filter:"+[OpenTween*]* -[OpenTween.Tests]*" -excludebyfile:"*.Designer.cs" -skipautoprops -hideskipped:All -returntargetcode -output:coverage.xml
59
60 after_test:
61   - npm install codecov --save
62   - ./node_modules/.bin/codecov -f coverage.xml
63
64   - ps: |
65       $env:PATH = $env:PATH + ';C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Current\bin\Roslyn\;C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\'
66       $binDir = '.\OpenTween\bin\' + $env:CONFIGURATION + '\'
67       $objDir = '.\OpenTween\obj\' + $env:CONFIGURATION + '\'
68       $assemblyInfo = '.\OpenTween\Properties\AssemblyInfo.cs'
69       if ($env:RELEASE_TAG -eq 'true') {
70         $destPath = $env:APPVEYOR_REPO_TAG_NAME + '.zip'
71       } else {
72         $destPath = 'OpenTween_dev-' + $env:APPVEYOR_BUILD_NUMBER + '.zip'
73       }
74       .\tools\build-zip-archive.ps1 -BinDir $binDir -ObjDir $objDir -AssemblyInfo $assemblyInfo -DestPath $destPath
75
76 # vim: et fenc=utf-8 sts=2 sw=2 ts=2