forked from rscustom/rocksmith-custom-song-toolkit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor.yml
83 lines (70 loc) · 3.57 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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# script syntax is very sensitive - BE CAREFUL EDITING
version: "{build}"
branches:
only:
- master
configuration: Release
test: off
environment:
cert_url:
secure: +Hrnyb/2BCwM+8B+26euLJlIcgul2423FxzS82lgeI68j4GkQUPwQkOB8OxXJz/J
cert_pass:
secure: zNGTVLKEVu1EO1JzH/hLP9CjmiBtltp6ONytwV2ArUo=
build:
parallel: true
verbosity: minimal
project: RocksmithCustomSongCreator.sln
install:
- set PATH=C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin;%PATH%
# scripts to run before build
before_build:
- rem any PAUSE commands in a batch file will make AppVeyor hang ...
- ps: $env:GIT_HASH = $env:APPVEYOR_REPO_COMMIT.Substring(0, 8)
- ps: .\PatchAssemblyVersion.ps1 "$env:APPVEYOR_BUILD_FOLDER\RocksmithTookitGUI\Properties\AssemblyInfo.cs"
- ps: .\PatchAssemblyVersion.ps1 "$env:APPVEYOR_BUILD_FOLDER\RocksmithToolkitLib\Properties\AssemblyInfo.cs"
- ps: .\PatchAssemblyVersion.ps1 "$env:APPVEYOR_BUILD_FOLDER\RocksmithToolkitUpdater\Properties\AssemblyInfo.cs"
# scripts to run after build
after_build:
- set BIN=%APPVEYOR_BUILD_FOLDER%\RocksmithTookitGUI\bin
- set APPS=%APPVEYOR_BUILD_FOLDER%\RocksmithTookitGUI\ThirdPartyApps
- rem Code signing
- ps: if ($env:cert_url) { Start-FileDownload $env:cert_url }
- if defined cert_url signtool sign /v /f selfsigned2020.pfx /p "%cert_pass%" /tr http://timestamp.digicert.com /td sha256 /fd sha256 "%BIN%\Release\RocksmithToolkitGUI.exe" "%BIN%\Release\RocksmithToolkitUpdater.exe" "%BIN%\Release\RocksmithToolkitLib.dll"
- rem General package variables
- ps: $env:BuildVer = Select-String -Path $env:APPVEYOR_BUILD_FOLDER"\RocksmithToolkitLib\Properties\AssemblyInfo.cs" -Pattern '^\[assembly:\ AssemblyVersion\("(.*?)"\)\]' | % { $_.Matches } | % { $_.Groups[1].Value }
- ps: $env:BuildCommit = $env:APPVEYOR_REPO_COMMIT.Substring(0, 8)
- ps: $env:PkgName = "rstoolkit-" + $env:BuildVer + "-" + $env:BuildCommit
- rem Windows package
- rem ensure ThirdPartyApps are copied
- rem xcopy /E /S /Y "%APPS\*.*" "%BIN%\Release\*.*"
- mkdir "%BIN%\tmp"
- xcopy /E /S /Y "%BIN%\Release\*.*" "%BIN%\tmp\RocksmithToolkit\*.*"
- copy "%BIN%\Release\ReadMe.txt" "%BIN%\tmp\ReadMe.txt"
- copy "%BIN%\Release\tools\CreateToolkitShortcut.exe" "%BIN%\tmp\CreateToolkitShortcut.exe"
- del "%BIN%\Release\ReadMe.txt"
- del "%BIN%\Release\tools\CreateToolkitShortcut.exe"
- 7z a %PkgName%-win.zip %BIN%\tmp\*
- rem Mac package
- del "%BIN%\RocksmithCustomSongToolkit.app\Contents\Resources\gitkeep.txt"
- xcopy /E "%BIN%\Release\*" "%BIN%\RocksmithCustomSongToolkit.app\Contents\Resources\"
- xcopy "%APPVEYOR_BUILD_FOLDER%\RocksmithTookitGUI\songcreator.icns" "%BIN%\RocksmithCustomSongToolkit.app\Contents\Resources\"
- copy "%BIN%\Release\RocksmithToolkitGUI.exe" "%BIN%\RocksmithCustomSongToolkit.app\Contents\Resources\RocksmithCustomSongToolkit.exe"
- del "%BIN%\RocksmithCustomSongToolkit.app\Contents\Resources\RocksmithToolkitGUI.exe"
- 7z a %PkgName%-mac.zip "%BIN%\RocksmithCustomSongToolkit.app\"
- rem Sign artifacts to avoid lockups
- rem can't really sign any zip file tho
artifacts:
- path: '*-win.zip'
name: Windows
- path: '*-mac.zip'
name: Mac
# let us know about build state
notifications:
- provider: Webhook
url: "http://hook.rscustom.net/appveyor"
headers:
Authorization:
secure: NjVdRVVdkTGELbhe2ejYz/soldL9HWrzpaVcDpPM5tX0lYfFd0ld8Q2NowOfBiqxEKa1t7jgV6z8XO6B5g4nMM9rkqJwjzmrN8ZQbfIX7+Z2xokQo6A1ET4uadCfKrIOHPYBQyGaaimojJKJlq+Zzw+BsQD/OLDKf3u9q6MARyg=
on_build_success: true
on_build_failure: true
on_build_status_changed: true