-
Notifications
You must be signed in to change notification settings - Fork 3
38 lines (31 loc) · 879 Bytes
/
Copy pathdocs.yml
File metadata and controls
38 lines (31 loc) · 879 Bytes
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
name: Documentation
on:
push:
branches:
- main
release:
types: [published]
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Micromamba and create environment
uses: mamba-org/setup-micromamba@v1
with:
environment-file: environment.yml
init-shell: bash
cache-environment: true
- name: Build documentation
shell: bash -l {0}
run: |
sphinx-build -b html docs/ docs/_build/html
touch docs/_build/html/.nojekyll
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/_build/html
publish_branch: gh-pages
force_orphan: true # Optional: creates a clean gh-pages branch