generated from uwhackweek/jupyterbook-template
-
Notifications
You must be signed in to change notification settings - Fork 13
55 lines (46 loc) · 1.36 KB
/
qaqc.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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: QualityControl
on:
pull_request:
branches:
- main
jobs:
quality-control:
runs-on: ubuntu-20.04
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setupconda
- name: Install NB-Clean
run: |
pip install nb-clean==2.0.2
- name: Ensure clean notebooks
run: |
python .github/workflows/ensure_clean_notebooks.py
# NOTE: this isn't a comprehensive spellcheck, just common typos
- name: Spellcheck
if: always()
uses: codespell-project/actions-codespell@master
with:
check_filenames: true
check_hidden: true
skip: '*.js,*.css,qaqc.yml'
ignore_words_list: slippy,trough,thw
# borrowed from https://github.com/ProjectPythia/pythia-foundations/blob/main/.github/workflows/link-checker.yaml
- name: Disable Notebook Execution Before Linkcheck
if: always()
shell: python
run: |
import yaml
with open('./book/_config.yml') as f:
data = yaml.safe_load(f)
data['execute']['execute_notebooks'] = 'off'
with open('./book/_config.yml', 'w') as f:
yaml.dump(data, f)
- name: Check External Links
continue-on-error: true
timeout-minutes: 5
if: always()
run: |
jb build book --builder linkcheck