Skip to content

Commit 922f476

Browse files
committed
Add Actions workflow to build docs with Sphinx
1 parent 94cf950 commit 922f476

File tree

2 files changed

+35
-0
lines changed

2 files changed

+35
-0
lines changed

.github/workflows/sphinx.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Github Actions workflow to generate documentation
2+
# Uses the following shared task definitions:
3+
# - (checkout, upload artifact) from Github
4+
# - sphinx-action maintained by @ammaraskar
5+
name: Sphinx build
6+
7+
# Controls when the action will run.
8+
# Triggers the workflow on push or pull request events.
9+
on:
10+
- push
11+
- pull_request
12+
13+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
14+
jobs:
15+
# This workflow contains a single job called "build"
16+
build:
17+
# The type of runner that the job will run on
18+
runs-on: ubuntu-latest
19+
20+
# Steps are a sequence of tasks that will be executed as part of the job
21+
steps:
22+
# Check out repository under $GITHUB_WORKSPACE
23+
- uses: actions/checkout@v2
24+
# Builds docs using sphinx
25+
- uses: ammaraskar/sphinx-action@master
26+
with:
27+
docs-folder: "doc/"
28+
# Create an artifact out of the generated HTML
29+
- uses: actions/upload-artifact@v1
30+
with:
31+
name: UserGuideHTML
32+
path: "doc/_build/html/"

doc/requirements.txt

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
sphinx_rtd_theme
2+
sphinx_copybutton
3+

0 commit comments

Comments
 (0)