Skip to content

Commit 1fb12f2

Browse files
committed
Build docs in CI, without sphinx-action
1 parent 72a3a87 commit 1fb12f2

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

.github/workflows/docs.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# This file was modified from https://github.com/ammaraskar/sphinx-action-test/blob/master/.github/workflows/pull_request.yml
2+
3+
name: Pull Request Docs Check
4+
5+
on: [pull_request]
6+
7+
jobs:
8+
build:
9+
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v4
14+
- uses: actions/setup-python@v5
15+
with:
16+
python-version: '3.13'
17+
cache: 'pip' # caching pip dependencies
18+
# Standard drop-in approach that should work for most people.
19+
#- uses: ammaraskar/sphinx-action@7.3.7
20+
# with:
21+
# docs-folder: "docs/"
22+
# Example of using a custom build-command.
23+
#- uses: ammaraskar/sphinx-action@master
24+
# with:
25+
# build-command: "sphinx-build -b html . _build"
26+
# docs-folder: "docs2/"
27+
## Grabbing custom dependencies and building as a pdf.
28+
#- uses: ammaraskar/sphinx-action@master
29+
# with:
30+
# pre-build-command: "apt-get update -y && apt-get install -y latexmk texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended"
31+
# build-command: "make latexpdf"
32+
# docs-folder: "docs2/"
33+
# Great extra actions to compose with:
34+
# Create an artifact of the html output.
35+
- name: Install dependencies
36+
run: |
37+
python -m pip install --upgrade pip
38+
pip install -r docs/requirements.txt
39+
- name: Build documentation
40+
run: cd docs && make html
41+
- uses: actions/upload-artifact@v4
42+
with:
43+
name: DocumentationHTML
44+
path: docs/build/html/

0 commit comments

Comments
 (0)