Skip to content

Commit f1bd2a4

Browse files
committed
updated build action for docs
1 parent e945bdb commit f1bd2a4

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/build_docs.yml

+6-2
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@ name: docs
55
on:
66
push:
77
branches: [main]
8+
pull_request:
9+
branches: [main]
810
workflow_dispatch:
11+
912
jobs:
1013
build:
1114
name: Build the documentation with Sphinx
@@ -29,13 +32,14 @@ jobs:
2932
- name: Build documentation
3033
run: sphinx-build documentation/ documentation/_build/html
3134
- name: Upload artifact
32-
uses: actions/upload-pages-artifact@v1
35+
uses: actions/upload-pages-artifact@v3
3336
with:
3437
path: 'documentation/_build/html'
3538

3639
deploy:
3740
name: Deploy documentation to GitHub Pages
3841
needs: build
42+
if: github.event_name == 'push'
3943
permissions:
4044
contents: read
4145
pages: write # to deploy to Pages
@@ -49,4 +53,4 @@ jobs:
4953
uses: actions/configure-pages@v3
5054
- name: Deploy to GitHub Pages
5155
id: deployment
52-
uses: actions/deploy-pages@v1
56+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)