forked from Tenacom/AaaLib
-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (61 loc) · 1.8 KB
/
deploy-pages.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
name: Deploy documentation to GitHub Pages
on:
workflow_dispatch:
inputs:
cakeVerbosity:
description: 'Cake verbosity'
required: false
type: choice
default: 'Normal'
options:
- Normal
- Verbose
- Diagnostic
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
deploy-pages:
runs-on: windows-latest
permissions:
contents: read
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
env:
DOTNET_NOLOGO: 'true'
DOTNET_CLI_TELEMETRY_OPTOUT: 'true'
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 'true'
DOTNET_CLI_UI_LANGUAGE: 'en-US'
MYGET_PRIVATE_FEED_PASSWORD: ${{ secrets.MYGET_PRIVATE_FEED_PASSWORD }}
CAKE_VERBOSITY: ${{ inputs.cakeVerbosity }}
steps:
- name: Checkout repository with full history
uses: actions/checkout@v3
with:
fetch-depth: 0 # Checkout with full history so nbgv can compute Git height correctly.
- name: Setup .NET SDK
uses: actions/setup-dotnet@v3
with:
global-json-file: global.json
- name: Restore .NET tools
shell: cmd
run: dotnet tool restore
- name: Run Cake script to build documentation
shell: cmd
run: |
if [%CAKE_VERBOSITY%]==[] set CAKE_VERBOSITY=Normal
if [%RUNNER_DEBUG%]==[1] set CAKE_VERBOSITY=Diagnostic
dotnet cake docs.cake --target All --verbosity %CAKE_VERBOSITY%
- name: Setup GitHub Pages
uses: actions/configure-pages@v3
- name: Upload documentation artifact
uses: actions/upload-pages-artifact@v1
with:
path: docs/_site/
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v1