-
-
Notifications
You must be signed in to change notification settings - Fork 158
/
Copy pathappveyor.yml
110 lines (94 loc) · 2.93 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
version: '{build}'
os: Visual Studio 2019
environment:
PGUSER: postgres
PGPASSWORD: Password12!
ACCESS_TOKEN:
secure: g1T332Uarmdgtkftchpafa8tDP/7eM4O0BD6iu1wu+zR224IyH5R8pb4sTChr4Ia
# REF: https://github.com/docascode/docfx-seed/blob/master/appveyor.yml
before_build:
- pwsh: |
if (-Not $env:APPVEYOR_PULL_REQUEST_TITLE) {
# https://dotnet.github.io/docfx/tutorial/docfx_getting_started.html
git checkout $env:APPVEYOR_REPO_BRANCH -q
}
choco install docfx -y
after_build:
- pwsh: |
CD ./docs
& ./generate-examples.ps1
& docfx docfx.json
if ($lastexitcode -ne 0) {
throw [System.Exception] "docfx build failed with exit code $lastexitcode."
}
git config --global credential.helper store
Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:ACCESS_TOKEN):[email protected]`n"
git config --global user.email "[email protected]"
git config --global user.name "Jared Nance"
git config --global core.autocrlf false
git config --global core.safecrlf false
git clone https://github.com/json-api-dotnet/JsonApiDotNetCore.git -b gh-pages origin_site -q
Copy-Item origin_site/.git _site -recurse
Copy-Item CNAME _site/CNAME
Copy-Item home/*.html _site/
Copy-Item home/*.ico _site/
Copy-Item -Recurse home/assets/* _site/styles/
CD _site
git add -A 2>&1
git commit -m "CI Updates" -q
if (-Not $env:APPVEYOR_PULL_REQUEST_TITLE) {
git push origin gh-pages -q
echo "Documentation updated successfully."
}
pull_requests:
do_not_increment_build_number: true
branches:
only:
- master
- develop
- unstable
- /release\/.+/
nuget:
disable_publish_on_pr: true
init:
- SET PATH=C:\Program Files\PostgreSQL\9.6\bin\;%PATH%
services:
- postgresql96
build_script:
- pwsh: dotnet --version
- pwsh: .\Build.ps1
test: off
artifacts:
- path: .\**\artifacts\**\*.nupkg
name: NuGet
deploy:
- provider: NuGet
server: https://www.myget.org/F/research-institute/api/v2/package
api_key:
secure: 6CeYcZ4Ze+57gxfeuHzqP6ldbUkPtF6pfpVM1Gw/K2jExFrAz763gNAQ++tiacq3
skip_symbols: false
symbol_server: https://www.myget.org/F/research-institute/symbols/api/v2/package
on:
branch: develop
- provider: NuGet
server: https://www.myget.org/F/jadnc/api/v2/package
api_key:
secure: 6CeYcZ4Ze+57gxfeuHzqP6ldbUkPtF6pfpVM1Gw/K2jExFrAz763gNAQ++tiacq3
skip_symbols: false
on:
branch: unstable
- provider: NuGet
name: production
skip_symbols: false
api_key:
secure: SirU21S2S6F1OswSl8oiB4lYLLPchyyCIqtd2sWkTgHluelYfTa4PRaAfxlZP4fg
on:
branch: master
appveyor_repo_tag: true
- provider: NuGet
skip_symbols: false
api_key:
secure: SirU21S2S6F1OswSl8oiB4lYLLPchyyCIqtd2sWkTgHluelYfTa4PRaAfxlZP4fg
on:
branch: /release\/.+/
appveyor_repo_tag: true