Skip to content

Commit f3d93f8

Browse files
committed
add workflow for jupyter book creation
1 parent 0629880 commit f3d93f8

1 file changed

Lines changed: 40 additions & 0 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: deploy-documentation
2+
3+
# Only run this when the master branch changes
4+
on:
5+
push:
6+
branches:
7+
- main
8+
# Only run if edits in DS-documentation
9+
paths:
10+
- documentation/CP-plugins-documentation/**
11+
- .github/workflows/deploy.yml
12+
13+
# This job installs dependencies, builds the book, and pushes it to `gh-pages`
14+
jobs:
15+
deploy-book:
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v2
19+
20+
# Install dependencies
21+
- name: Set up Python 3.8
22+
uses: actions/setup-python@v2
23+
with:
24+
python-version: 3.8
25+
26+
- name: Install dependencies
27+
run: |
28+
pip install jupyter-book
29+
30+
# Build the book
31+
- name: Build the book
32+
run: |
33+
jupyter-book build documentation/DS-documentation/
34+
35+
# Push the book's HTML to github-pages
36+
- name: GitHub Pages action
37+
uses: peaceiris/actions-gh-pages@v3.6.1
38+
with:
39+
github_token: ${{ secrets.GITHUB_TOKEN }}
40+
publish_dir: ./documentation/DS-documentation/_build/html

0 commit comments

Comments
 (0)