-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (38 loc) · 1.17 KB
/
static.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
on:
push:
branches: ["dev"]
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
publish-docs:
runs-on: ubuntu-latest
steps:
- name: Chekout
uses: actions/checkout@v3
- name: Dotnet Setup
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.x
- run: dotnet tool update -g docfx
- run: dotnet tool install DocFxTocGenerator -g
- run: DocFxTocGenerator -d ./zh/ater.web -r -g -s
- run: DocFxTocGenerator -d ./zh/ater.dry -r -g -s
- run: DocFxTocGenerator -d ./en/ater.web -r -g -s
- run: DocFxTocGenerator -d ./en/ater.dry -r -g -s
- run: docfx build ./zh/docfx-zh.json
- run: docfx build ./en/docfx-en.json
- run: rm -rf ./_site/styles/*.map
- run: cp -f ./src/index.html ./_site/
- name: Upload GitHub Pages artifact
uses: actions/[email protected]
- name: Deploy GitHub Pages site
uses: actions/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}