1010jobs :
1111 build_docs :
1212 if : (github.event_name == 'push' || (github.event_name == 'pull_request_target' && github.event.action != 'closed' && github.event.action != 'unlabeled' && contains(github.event.pull_request.labels.*.name, 'pr-generate-docs-preview'))) && github.repository_owner == 'GmodNET'
13- runs-on : windows -latest
13+ runs-on : ubuntu -latest
1414 name : Build Docs
1515 steps :
16- - name : Install DocFX
17- run : choco install docfx --version=2.59.4 -y
18-
1916 - name : Checkout branch
2017 if : github.event_name == 'push'
2118@@ -28,32 +25,27 @@ jobs:
2825 env :
2926 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
3027
31- - name : Install .NET SDK
32- 28+ - name : Setup .NET Core SDK
29+ 30+ with :
31+ dotnet-version : 6.0.x
32+ global-json-file : " ./global.json"
33+
34+ - name : Install DocFX
35+ run : dotnet tool update -g docfx
3336
3437 - name : Build docs with DocFX
3538 shell : pwsh
3639 run : |
3740 $env:GITHUB_ACTIONS='false'
38- docfx .\ docfx_project\ docfx.json
41+ docfx ./ docfx_project/ docfx.json
3942
4043 - name : Upload docs as artifact
41444245 with :
4346 name : site
4447 path : docfx_project/_site/
4548
46- deploy_docs :
47- needs : build_docs
48- runs-on : ubuntu-latest
49- name : Deploy Docs
50- steps :
51- - name : Dowload docs build
52- 53- with :
54- name : site
55- path : site
56-
5749 - name : Deploy docs
5850 uses : Azure/static-web-apps-deploy@v1
5951 with :
6254 action : " upload"
6355 # ##### Repository/Build Configurations - These values can be configured to match your app requirements. ######
6456 # For more information regarding Static Web App workflow configurations, please visit: https://aka.ms/swaworkflowconfig
65- app_location : " ./site " # App source code path
57+ app_location : " ./docfx_project/_site/ " # App source code path
6658 api_location : " " # Api source code path - optional
6759 output_location : " " # Built app content directory - optional
6860 skip_app_build : true
0 commit comments