-
Notifications
You must be signed in to change notification settings - Fork 5
55 lines (47 loc) · 1.29 KB
/
update-wiki.yml
File metadata and controls
55 lines (47 loc) · 1.29 KB
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
name: update-wiki
on:
push:
branches:
- main
env:
# Specifies dotnet SDK Version
DOTNET_VERSION: '8.0.x'
jobs:
ci:
name: update-wiki-job
runs-on: ubuntu-latest
permissions:
contents: write
steps:
# Checks out the source code at the latest commit
- name: checkout source
uses: actions/checkout@v4
with:
fetch-depth: 0
path: ${{github.repository}}
- name: checkout wiki
uses: actions/checkout@v3
with:
repository: ${{github.repository}}.wiki
path: ${{github.repository}}.wiki
# Installs the .NET SDK on the build machine
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: ${{ env.DOTNET_VERSION }}
# Generate the Wiki with docfx from the XML documentation comments
- name: Create Wiki
shell: pwsh
run: |
Push-Location ${{github.repository}}
dotnet tool update -g docfx
pwsh ".github/workflows/build_wiki.ps1"
Pop-Location
- name: Commit and push changes
run: |
cd ${{github.repository}}.wiki
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add .
git commit -m "Add changes"
git push