-
Notifications
You must be signed in to change notification settings - Fork 145
40 lines (38 loc) · 1.04 KB
/
publish_docs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Build & publish documentation to GitHub Pages
on:
push:
branches:
- main
release:
jobs:
build-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
fetch-depth: 0
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install pandoc
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -e ".[docs]"
- name: Build documentation
run: sphinx-build -b html -d _build/doctrees . _build/html
working-directory: docs
- name: Deploy to GitHub Pages
if: success()
uses: crazy-max/ghaction-github-pages@v3
with:
target_branch: gh-pages
build_dir: docs/_build/html
fqdn: docs.stingray.science
jekyll: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}