-
-
Notifications
You must be signed in to change notification settings - Fork 2
49 lines (44 loc) · 1.34 KB
/
sphinx.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
47
48
49
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow
name: "Sphinx"
on: # yamllint disable-line rule:truthy
pull_request:
paths:
- "**/*.rst"
push:
branches:
- "master"
paths:
- "**/*.rst"
workflow_call: null
# Add [skip ci] to commit message to skip CI.
permissions: {} # yamllint disable-line rule:braces
#permissions: "read-all"
#permissions:
# contents: "read" # Private repositories need read permission
concurrency:
group: "${{ github.workflow }}-${{ github.ref }}"
cancel-in-progress: true
jobs:
sphinx:
name: "Sphinx reStructuredText validity"
runs-on: "ubuntu-22.04"
timeout-minutes: 1
steps:
-
name: "Checkout repository"
uses: "actions/[email protected]"
-
name: "Cache pip"
uses: "actions/[email protected]"
with:
path: "~/.cache/pip"
key: "${{ runner.os }}-pip-sphinx-lint"
-
name: "Install sphinx-lint"
run: |
pip install --user sphinx-lint
-
name: "Check Sphinx document sources"
run: |
git ls-files --cached -z -- '*.rst' \
| xargs --null -- python -m sphinxlint --enable all --max-line-length 120