-
Notifications
You must be signed in to change notification settings - Fork 20
41 lines (33 loc) · 1.13 KB
/
deploy-jupyter-book.yml
File metadata and controls
41 lines (33 loc) · 1.13 KB
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
name: Deploy Jupyter Book
on:
push:
pull_request:
jobs:
deploy-book:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
python -m pip install --no-cache-dir -r requirements.txt
python -m pip install --no-cache-dir -r book/requirements.txt
python -m pip list
- name: Build the book
run: |
jupyter-book build book/
# cp book/_static/* book/_build/html/_static
- name: Deploy Jupyter book to GitHub pages
if: success() && github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository == 'cranmer/stats-ds-book'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: book/_build/html
force_orphan: true
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
commit_message: Deploy to GitHub pages