This repository has been archived by the owner on Oct 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
/
appveyor.yml
79 lines (68 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
version: 1.0.10.{build}
pull_requests:
do_not_increment_build_number: true
branches:
except:
- gh-pages
image: Visual Studio 2017
configuration:
- Release
environment:
gp_build_user: ObsidianMinor
gp_build_user_email: [email protected]
access_token:
secure: hbO0PhmlEaYZiDRbliEBxSbB8qQBnE0e4XxRvW7GhLRdlYO5/CGwbsaMgUBMov1N
build_script:
- ps: >-
if(-Not ($env:APPVEYOR_PULL_REQUEST_TITLE) -and ($env:APPVEYOR_REPO_BRANCH -eq "master"))
{
git checkout $env:APPVEYOR_REPO_BRANCH -q
cinst docfx -y
}
dotnet restore src/Gfycat.Net/Gfycat.Net.csproj
dotnet restore src/Gfycat.Net.Analytics/Gfycat.Net.Analytics.csproj
dotnet restore tests/Gfycat.Net.Tests/Gfycat.Net.Tests.csproj
if(-Not $env:APPVEYOR_REPO_BRANCH -eq "master")
{
dotnet build Gfycat.Net.sln --configuration Release /p:Version=$env:APPVEYOR_BUILD_VERSION-$env:APPVEYOR_REPO_BRANCH
}
else
{
dotnet build Gfycat.Net.sln --configuration Release /p:Version=$env:APPVEYOR_BUILD_VERSION
}
if(-Not ($env:APPVEYOR_PULL_REQUEST_TITLE) -and ($env:APPVEYOR_REPO_BRANCH -eq "master"))
{
CD docs
docfx docfx.json
git config --global credential.helper store
Add-Content "$env:USERPROFILE\.git-credentials" "https://$($env:access_token):[email protected]`n"
git config --global user.email $env:gp_build_user_email
git config --global user.name $env:gp_build_user
git clone https://github.com/ObsidianMinor/Gfycat.Net.git -b gh-pages origin_site
Copy-Item origin_site/.git _site -recurse
CD _site
git add .
git commit -m "CI Updates"
git push origin gh-pages
CD ..\..
}
test_script:
- ps: dotnet test tests/Gfycat.Net.Tests/Gfycat.Net.Tests.csproj
artifacts:
- path: '**/Release/*$(APPVEYOR_BUILD_VERSION)*.nupkg'
name: Nuget Packages
deploy:
- provider: NuGet
api_key:
secure: lIIha19su56DoSb9z5LilA8cIKhNsph/NqxUxIYdh+4XJq67ZRt+1Fkohqx8RHh0
artifact: /.*\.nupkg/
on:
branch: master
- provider: NuGet
server: https://www.myget.org/F/gfycat-net/api/v2/package
api_key:
secure: dC/r9sWakZvZKWAD+yiakvdXWOZWvCfRtDFkIb8B19T1X0WoZqblJFkfpnKRsmhd
skip_symbols: true
artifact: /.*\.nupkg/
on:
branch: dev