Skip to content

Commit cee47c0

Browse files
committed
update sphinx workflow
1 parent 468487b commit cee47c0

File tree

3 files changed

+31
-29
lines changed

3 files changed

+31
-29
lines changed

.github/workflows/sphinx.yml

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -8,31 +8,31 @@ jobs:
88
permissions:
99
contents: write
1010
steps:
11-
- uses: actions/checkout@v4
12-
with:
13-
persist-credentials: false
14-
- name: Set up Python
15-
uses: actions/setup-python@v5
16-
with:
17-
python-version: '3.11'
18-
- name: Install dependencies
19-
run: |
20-
python -m pip install --upgrade pip
21-
pip install -r docs/requirements.txt
22-
- name: Install your package
23-
run: pip install -e .
24-
- name: Build docs with clean rebuild
25-
run: |
26-
sphinx-build -a -E -b html docs/source docs/build/html
27-
- name: Upload artifacts
28-
uses: actions/upload-artifact@v4
29-
with:
30-
name: html-docs
31-
path: docs/build/html/
32-
- name: Deploy
33-
uses: peaceiris/actions-gh-pages@v3
34-
if: github.ref == 'refs/heads/main'
35-
with:
36-
github_token: ${{ secrets.GITHUB_TOKEN }}
37-
publish_dir: docs/build/html
38-
force_orphan: true
11+
- uses: actions/checkout@v4
12+
with:
13+
persist-credentials: false
14+
- name: Set up Python
15+
uses: actions/setup-python@v5
16+
with:
17+
python-version: "3.11"
18+
- name: Install dependencies
19+
run: |
20+
python -m pip install --upgrade pip
21+
pip install -r docs/requirements.txt
22+
- name: Install your package
23+
run: pip install -e .
24+
- name: Build multiversion docs
25+
run: |
26+
sphinx-multiversion docs/source docs/build/html
27+
- name: Upload artifacts
28+
uses: actions/upload-artifact@v4
29+
with:
30+
name: html-docs
31+
path: docs/build/html/
32+
- name: Deploy
33+
uses: peaceiris/actions-gh-pages@v3
34+
if: github.ref == 'refs/heads/main'
35+
with:
36+
github_token: ${{ secrets.GITHUB_TOKEN }}
37+
publish_dir: docs/build/html
38+
force_orphan: true

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@
55
build
66
pyshred/sst copy.ipynb
77
pyshred/sst_figures.ipynb
8+
docs/_build

docs/requirements.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
sphinx>=8.0
22
pydata-sphinx-theme
33
myst-parser
4-
sphinx-design
4+
sphinx-design
5+
sphinx-multiversion

0 commit comments

Comments
 (0)