-
Notifications
You must be signed in to change notification settings - Fork 3
39 lines (37 loc) · 1.18 KB
/
docs_deploy.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
name: Deploy Documentation
on:
push:
branches: [master]
jobs:
deploy-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: "3.11"
- name: Install dependencies
run: |
sudo apt-get install pandoc
python -m pip install --upgrade pip wheel
pip install numpy==1.26.4
pip install -r doc/requirements.txt
- name: Compile Cython components
run: |
make compile
- name: Build documentation
run: |
cd doc
make html
- name: Deploy documentation to GitHub pages
run: |
cd doc/_build/html
touch .nojekyll
git config --global init.defaultBranch master
git config --global user.name "CovertLab [bot]"
git config --global user.email "[email protected]"
git init
git add -A
git commit -m "Sphinx build from commit $GITHUB_SHA by GitHub Action"
git push -f "https://$GITHUB_ACTOR:${{ secrets.GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY.git" master:gh-pages