-
Notifications
You must be signed in to change notification settings - Fork 111
46 lines (37 loc) · 1.1 KB
/
build_book_on_pr.yml
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
46
---
name: build-book
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
# run on pushes and pull requests to main
on:
pull_request:
branches:
- main
# This job installs dependencies, build the book, and pushes it to `gh-pages`
jobs:
build-book:
if: (github.event.pull_request) && !contains(github.head_ref, 'all-contributors')
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python_version: ['3.10', '3.11', '3.12']
fail-fast: false # Don't cancel all jobs if one fails
runs-on: ${{ matrix.os }}
steps:
- name: Checkout-repository
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Setup Python ${{ matrix.python_version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python_version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
pip install -r requirements.txt
# Build the book
- name: Build the book
run: make book