-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (32 loc) · 935 Bytes
/
deploy.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
name: deploy-book
on: [ push ]
jobs:
deploy-book:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Install dependencies
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
make setup
# Check external links in the book
- name: Check external links
run: |
make check
# Build the book
- name: Build the book
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
run: |
make build
# Push the book's HTML to github-pages
- name: GitHub Pages action
uses: peaceiris/[email protected]
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./_build/html
publish_branch: gh-pages # deploying branch