-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (43 loc) · 1.49 KB
/
build-docs-site.yaml
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
name: CISL Docs CI/CD
on:
push:
paths:
- cisl-docs/**
jobs:
build-docs:
runs-on: ubuntu-latest
steps:
# Step 1 is to checkout the github repo
- name: Check out the repo
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install Python dependencies
run: |
sudo apt-get install python3-pip
pip install ghp-import
pip install jupyter-book
pip install sphinx_pythia_theme
pip install sphinxcontrib-applehelp==1.0.4
pip install sphinxcontrib-bibtex==2.5.0
pip install sphinxcontrib-devhelp==1.0.2
pip install sphinxcontrib-htmlhelp==2.0.1
pip install sphinxcontrib-serializinghtml==1.1.5
pip install sphinxcontrib-qthelp==1.0.3
PATH="${PATH}:${HOME}/.local/bin"
- name: Show Sphinx versions
run: |
pip freeze |grep -i sphinx
- name: Build book HTML
run: |
jupyter-book build cisl-docs/.
- name: Push _build/html to gh-pages
run: |
sudo chown -R $(whoami):$(whoami) .
git config --global user.email "[email protected]"
git config --global user.name "$GITHUB_ACTOR"
git remote set-url origin "https://$GITHUB_ACTOR:${{ secrets.NC_GITHUB_TOKEN }}@github.com/$GITHUB_REPOSITORY"
ls -lrt
ghp-import -n -p -f cisl-docs/_build/html