Skip to content

Commit d1b8ed0

Browse files
Revert publish-documentation.yml
This is a revert to the last known working version.
1 parent 5827aee commit d1b8ed0

File tree

1 file changed

+63
-20
lines changed

1 file changed

+63
-20
lines changed
+63-20
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,84 @@
1-
name: Deploy Documentation to GitHub Pages
1+
name: Publish Documentation
22

33
on:
4+
# Runs on pushes targeting the default branch
45
push:
56
branches:
67
- master
8+
# Allows you to run this workflow manually from the Actions tab
79
workflow_dispatch:
810

9-
jobs:
10-
deploy:
11-
runs-on: ubuntu-latest
11+
env:
12+
DOTNET_NOLOGO: true # Disable the .NET logo in the console output
13+
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true # Disable the .NET first time experience to skip caching NuGet packages and speed up the build
14+
DOTNET_CLI_TELEMETRY_OPTOUT: true
15+
16+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
17+
permissions:
18+
contents: read
19+
pages: write
20+
id-token: write
1221

13-
permissions:
14-
pages: write # Grants access to publish to Pages
15-
id-token: write
22+
# Allow one concurrent deployment
23+
concurrency:
24+
group: "pages"
25+
cancel-in-progress: true
1626

27+
jobs:
28+
deploy:
29+
defaults:
30+
run:
31+
shell: pwsh
32+
environment:
33+
name: github-pages
34+
url: ${{ steps.deployment.outputs.page_url }}
35+
runs-on: windows-latest
1736
steps:
18-
- name: Checkout the repository
19-
uses: actions/checkout@v4
37+
- run: echo "🎉 The job was automatically triggered by a ${{ github.event_name }} event."
38+
- run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by GitHub!"
39+
- run: echo "🔎 The name of your branch is ${{ github.ref }} and your repository is ${{ github.repository }}."
2040

21-
- name: Setup .NET
22-
uses: actions/setup-dotnet@v4
41+
- name: Check out repository code
42+
uses: actions/checkout@v3
43+
- run: echo "💡 The ${{ github.repository }} repository has been cloned to the runner."
44+
45+
- name: List files in the repository
46+
run: |
47+
ls ${{ github.workspace }}
48+
- name: Setup DocFX
49+
uses: crazy-max/ghaction-chocolatey@v2
2350
with:
24-
dotnet-version: '8.0.403'
51+
args: install docfx
2552

26-
- name: Build Documentation
53+
- name: Build
2754
run: |
28-
dotnet tool install --global docfx
29-
docfx docfx.json --output ./_site
55+
cd ${{ github.workspace }}/Source/TimeWarp.State.Analyzer/
56+
dotnet clean --configuration Release
57+
dotnet build --configuration Release
58+
cd ${{ github.workspace }}/Source/TimeWarp.State.SourceGenerator/
59+
dotnet clean --configuration Release
60+
dotnet build --configuration Release
61+
cd ${{ github.workspace }}/Source/TimeWarp.State/
62+
dotnet clean --configuration Release
63+
dotnet build --configuration Release
64+
cd ${{ github.workspace }}/Source/TimeWarp.State.Plus/
65+
dotnet clean --configuration Release
66+
dotnet build --configuration Release
67+
- name: DocFX Build
3068
working-directory: Documentation
69+
run: docfx docfx.json
70+
continue-on-error: false
3171

32-
- name: Upload artifact for GitHub Pages
33-
uses: actions/upload-artifact@v4
72+
- name: Setup Pages
73+
uses: actions/configure-pages@v2
74+
- name: Upload artifact
75+
uses: actions/upload-pages-artifact@v1
3476
with:
35-
name: 'github-pages'
77+
# Upload entire repository
3678
path: './Documentation/_site'
3779

3880
- name: Deploy to GitHub Pages
81+
id: deployment
3982
uses: actions/deploy-pages@v1
40-
with:
41-
artifact_name: 'github-pages'
83+
84+
- run: echo "🍏 This job's status is ${{ job.status }}."

0 commit comments

Comments
 (0)