-
Notifications
You must be signed in to change notification settings - Fork 1
46 lines (45 loc) · 1.19 KB
/
gh-pages.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
41
42
43
44
45
46
name: Deploy GitHub Pages
on:
push:
branches:
- version2.0 # Set a branch name to trigger deployment
jobs:
deploy:
runs-on: ubuntu-20.04
permissions:
contents: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v3
with:
context: .
submodules: true
fetch-depth: 0
- name: Set up Python
uses: actions/[email protected]
with:
context: .
python-version: 3.9
- name: Install sphinx
run: |
pip install sphinx
pip install furo
pip install sphinx-togglebutton
pip install sphinx-favicon
pip install sphinxcontrib.bibtex
- name: Build
run: |
cd docs/doc-sphinx/
make clean
make html
cp source/index_replace.html build/html/index.html
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
if: ${{ github.ref == 'refs/heads/version2.0' }}
with:
context: .
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/