-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (53 loc) · 1.69 KB
/
docfx.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
name: DocFx Clone, Build And Push
on:
push:
branches:
- main
workflow_dispatch:
jobs:
clone_build_and_push:
runs-on: windows-latest
name: Clone, Build And Push
env:
DOCS_PATH: docs
DOCS_PROJECT: docfx_project
SOLUTION_FILE: Yugen.Toolkit.sln
PROJECT_PATH: Yugen.Toolkit
PROJECT_FOLDER: Yugen.Toolkit.Uwp.Controls
PROJECT_FILE: Yugen.Toolkit.Uwp.Controls.csproj
PROJECT_CONFIGURATION: Release
steps:
- name: Dotnet Setup
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.x
- name: Checkout Docs
uses: actions/checkout@v3
with:
path: ${{ env.DOCS_PATH }}
- name: Checkout Source
uses: actions/checkout@v3
with:
repository: Yugen-Apps/Yugen.Toolkit
token: ${{ secrets.GITHUB_TOKEN }}
path: ${{ env.PROJECT_PATH }}
- name: Setup NuGet
uses: nuget/setup-nuget@v1
- name: Restore dependencies
run: nuget restore ${{ env.PROJECT_PATH }}/${{ env.SOLUTION_FILE }}
- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1
- name: MSBuild Build
run: |
msbuild ${{ env.PROJECT_PATH }}/${{ env.PROJECT_FOLDER }}/${{ env.PROJECT_FILE }} `
/p:Configuration=${{ env.PROJECT_CONFIGURATION }} `
/p:TargetFramwork=uap10.0.18362 `
/p:Platform=x64
- run: dotnet tool update -g docfx
- run: docfx ${{ env.DOCS_PATH }}/${{ env.DOCS_PROJECT }}/docfx.json
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ${{ env.DOCS_PATH }}/${{ env.DOCS_PROJECT }}/_site
allow_empty_commit: true