Skip to content

Commit 874a072

Browse files
committed
Split docs deploy and build workflows
1 parent 81324fe commit 874a072

File tree

2 files changed

+50
-2
lines changed

2 files changed

+50
-2
lines changed

.github/workflows/docs.yml .github/workflows/build-docs.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Deploy documentation
1+
name: Build documentation
22

33
on:
44
push:
@@ -55,4 +55,4 @@ jobs:
5555
uses: actions/upload-artifact@v4
5656
with:
5757
name: docs-artifact
58-
path: docs/build/
58+
path: docs/_build/html/

.github/workflows/deploy-docs.yml

+48
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Deploy documentation
2+
3+
on:
4+
# Only trigger on pushes to master
5+
push:
6+
branches: [ "master" ]
7+
8+
# Optionally trigger on releases (created/published)
9+
release:
10+
types: [created, published]
11+
12+
# Allow manual triggering
13+
workflow_dispatch:
14+
15+
permissions:
16+
contents: read
17+
pages: write
18+
id-token: write
19+
20+
concurrency:
21+
group: "pages"
22+
cancel-in-progress: false
23+
24+
jobs:
25+
deploy-docs:
26+
environment:
27+
name: github-pages
28+
url: ${{ steps.deployment.outputs.page_url }}
29+
runs-on: ubuntu-latest
30+
31+
steps:
32+
- name: Download docs artifact
33+
uses: actions/download-artifact@v3
34+
with:
35+
name: docs-artifact
36+
37+
- name: Setup Pages
38+
uses: actions/configure-pages@v5
39+
40+
- name: Upload artifact
41+
uses: actions/upload-pages-artifact@v3
42+
with:
43+
# Adjust to the path where your built documentation resides
44+
path: './docs/_build/html'
45+
46+
- name: Deploy to GitHub Pages
47+
id: deployment
48+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)