forked from architdate/PKHeX-Plugins
-
Notifications
You must be signed in to change notification settings - Fork 0
/
appveyor.yml
137 lines (106 loc) · 5.73 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
version: 1.0.{build}
image: Visual Studio 2019
configuration: Release
init:
- cmd: set PATH=C:\Python35;C:\Python35\Scripts;%path%
environment:
latestcommit: false
notifyall: true
before_build:
- ps: >-
New-Variable -Name "nugetver" -Visibility Public -Value "19.12.27"
git clone -q --depth=5 --branch=master https://github.com/kwsch/PKHeX.git C:\projects\pkhex
Set-Location -Path "C:\projects\pkhex"
$env:pkhex_commit = $(git rev-parse --short HEAD)
$env:mod_commit = $env:APPVEYOR_REPO_COMMIT.Substring(0,7)
Add-AppveyorMessage $env:pkhex_commit
Add-AppveyorMessage $env:mod_commit
if ($env:notifyall -eq "true") { Add-AppveyorMessage "notify" }
nuget restore
msbuild C:\projects\pkhex\PKHeX.sln /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" /verbosity:minimal /p:DefineConstants=UNSAFEDLL /p:Configuration=Release
Copy-Item "C:\projects\pkhex\PKHeX.Core\bin\Release\net46\PKHeX.Core.dll" "C:\projects\pkhex-plugins"
Set-Location -Path "C:\projects\pkhex-plugins"
dotnet restore
nuget restore
#Copy-Item "C:\projects\pkhex\PKHeX.Core\bin\Release\net46\PKHeX.Core.dll" "C:\Users\appveyor\.nuget\packages\pkhex.core\$nugetver\lib\net46"
#Copy-Item "C:\projects\pkhex\PKHeX.Core\bin\Release\netstandard2.0\PKHeX.Core.dll" "C:\Users\appveyor\.nuget\packages\pkhex.core\$nugetver\lib\netstandard2.0"
#Copy-Item "C:\projects\pkhex\PKHeX.Core\bin\Release\net46\PKHeX.Core.dll" "C:\projects\pkhex-plugins\packages\PKHeX.Core.$nugetver\lib\net46"
#Copy-Item "C:\projects\pkhex\PKHeX.Core\bin\Release\netstandard2.0\PKHeX.Core.dll" "C:\projects\pkhex-plugins\packages\PKHeX.Core.$nugetver\lib\netstandard2.0"
build:
project: C:\projects\pkhex-plugins\PKHeX-Plugins.sln
verbosity: minimal
before_package:
- cmd: >-
mkdir base
xcopy C:\projects\pkhex\pkhex.winforms\bin\release C:\projects\pkhex-plugins\base /e /i /h
after_build:
- cmd: >-
mkdir bin
nuget install ILMerge -ExcludeVersion
cd "C:\projects\pkhex-plugins\ILMerge\tools\net452"
xcopy C:\projects\PKHeX-Plugins\AutoLegalityMod\bin\Release\AutoModPlugins.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\QRPlugins\bin\Release\net46\BouncyCastle.CryptoExt.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\QRPlugins\bin\Release\net46\QRCoder.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\QRPlugins\bin\Release\net46\zxing.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\QRPlugins\bin\Release\net46\zxing.presentation.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\QRPlugins\bin\Release\net46\QRPlugins.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\AutoLegalityMod\bin\Release\PKHeX.Core.AutoMod.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
xcopy C:\projects\PKHeX-Plugins\AutoLegalityMod\bin\Release\PKHeX.Core.dll C:\projects\pkhex-plugins\ILMerge\tools\net452
ilmerge /targetplatform:v4,"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6" /out:C:\projects\pkhex-plugins\bin\AutoModPlugins.dll AutoModPlugins.dll PKHeX.Core.AutoMod.dll
ilmerge /targetplatform:v4,"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.6" /out:C:\projects\pkhex-plugins\bin\QRPlugins.dll QRPlugins.dll PKHeX.Core.AutoMod.dll BouncyCastle.CryptoExt.dll QRCoder.dll zxing.dll zxing.presentation.dll
artifacts:
- path: bin
name: PKHeX-Plugins-$(mod_commit)
- path: base
name: PKHeX-$(pkhex_commit)-Unmerged
notifications:
- provider: Webhook
url:
secure: XmxZS8u/xG8nB6Kc5LePdDVVsPRNX7ryjU/Tgd53qI7aqkZ7Mk0KdwBAYfT26d6g/lMgMOC5CKULYn+UGjd5R/FAJ9pQudtgFoQ5tnU+yM1eMBnOGpj/J/5gSkpz3qFhsaNzJcDwXFpthUIocvhH32vzf+ItsqIz6QFX6dSiyh8=
method: POST
headers:
User-Agent: AppVeyor/PKHeX-Plugins
body: >-
{
{{#jobs}}{{#messages.2}}{{#passed}}"content": "<@&409770274074918925>",
{{/passed}}{{/messages.2}}{{/jobs}}"embeds": [
{
"title": "Build {{buildId}}",
"url": "{{buildUrl}}",
"color": "{{#passed}}40973{{/passed}}{{^passed}}11672839{{/passed}}",
"footer": {
"icon_url": "{{#passed}}https://i.imgur.com/Rf4g8v6.png{{/passed}}{{^passed}}https://i.imgur.com/QaERwAW.png{{/passed}}",
"text": "{{#passed}}Success{{/passed}}{{^passed}}Failure{{/passed}}"
},
"author": {
"name": "{{commitAuthor}}",
"url": "https://github.com/{{repositoryName}}/commit/{{commitId}}"
},
"fields": [
{
"name": "PKHeX Commit Hash",
"value": "{{#jobs}}{{#messages.0}}{{message}}{{/messages.0}}{{/jobs}}",
"inline": true
},
{
"name": "Mod Commit Hash",
"value": "{{#jobs}}{{#messages.1}}{{message}}{{/messages.1}}{{/jobs}}",
"inline": true
},
{
"name": "Artifact",
"value": "{{#passed}}Unmerged Base PKHeX: [Download]({{#jobs}}{{#artifacts.0}}{{permalink}}{{/artifacts.0}}{{/jobs}}) \nPlugins: [Download]({{#jobs}}{{#artifacts.1}}{{permalink}}{{/artifacts.1}}{{/jobs}}){{/passed}}{{^passed}}Build Failed{{/passed}}",
"inline": true
},
{
"name": "Build version",
"value": "{{buildVersion}}",
"inline": true
}
]
}
]
}
on_build_success: true
on_build_failure: true
on_build_status_changed: false