File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : deploy-book
2+
3+ # Run this when the master or main branch changes
4+ on :
5+ push :
6+ branches :
7+ - master
8+ paths :
9+ - docs/guide/**
10+
11+ # This job installs dependencies, builds the book, and pushes it to `gh-pages`
12+ jobs :
13+ deploy-book :
14+ runs-on : ubuntu-latest
15+ permissions :
16+ pages : write
17+ id-token : write
18+ steps :
19+ - uses : actions/checkout@v4
20+
21+ # Install dependencies
22+ - name : Set up Python 3.11
23+ uses : actions/setup-python@v5
24+ with :
25+ python-version : ' 3.11'
26+ cache : pip # Implicitly uses requirements.txt for cache key
27+
28+ - name : Install dependencies
29+ run : pip install -r requirements.txt
30+
31+ # Build the book
32+ - name : Build the book
33+ run : |
34+ jupyter-book build docs/guide
35+
36+ # Upload the book's HTML as an artifact
37+ - name : Upload artifact
38+ uses : actions/upload-pages-artifact@v3
39+ with :
40+ path : " docs/guide/_build/html"
41+
42+ # Deploy the book's HTML to GitHub Pages
43+ - name : Deploy to GitHub Pages
44+ id : deployment
45+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments