File tree Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Docs
2
+
3
+ on :
4
+ pull_request :
5
+ branches : [main, release/*]
6
+ push :
7
+ branches : [main, release/*]
8
+
9
+ # Cancel previous runs if new commit is pushed to the same PR
10
+ concurrency :
11
+ group : ${{ github.workflow }}-${{ github.event.pull_request.number || github.run_id }}
12
+ cancel-in-progress : true
13
+
14
+ # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
15
+ permissions :
16
+ contents : read
17
+ pages : write
18
+ id-token : write
19
+
20
+ jobs :
21
+ build-docs :
22
+ runs-on : ubuntu-latest
23
+ timeout-minutes : 15
24
+ steps :
25
+ - uses : actions/checkout@v4
26
+ - uses : actions/setup-python@v5
27
+ with :
28
+ python-version : " 3.12"
29
+ - name : Build docs
30
+ run : pip install tox && tox -e build-docs
31
+ - name : Upload docs artifact
32
+ if : github.event_name == 'push'
33
+ uses : actions/upload-pages-artifact@v3
34
+ with :
35
+ path : docs/build/html
36
+
37
+ deploy-gh-pages :
38
+ if : github.event_name == 'push'
39
+ needs : build-docs
40
+ runs-on : ubuntu-latest
41
+ environment :
42
+ name : github-pages
43
+ url : ${{ steps.deployment.outputs.page_url }}
44
+ steps :
45
+ - id : deployment
46
+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments