Skip to content

Commit 108e225

Browse files
authored
Create linkcheck.yml
1 parent 463437e commit 108e225

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

.github/workflows/linkcheck.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Run sphinx's linkcheck to pop up
2+
# broken and redirected links.
3+
4+
Name: Linkcheck
5+
6+
on:
7+
workflow_dispatch:
8+
9+
permissions:
10+
content: read
11+
12+
jobs:
13+
linkcheck:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Check out CPython
17+
uses: actions/checkout@v3
18+
with:
19+
repository: python/cpython
20+
persist-credentials: false
21+
22+
- name: Set up Python 3.9
23+
uses: actions/setup-python@v4
24+
with:
25+
python-version: '3.9'
26+
cache: 'pip'
27+
cache-dependency-path: 'Doc/requirements.txt'
28+
29+
- name: Make virtual environment
30+
run: |
31+
make -C Doc venv
32+
33+
- name: Run linkcheck
34+
run: |
35+
make -C Doc linkcheck \
36+
SPHINXOPTS="--keep-going"
37+
38+
- name: Upload output as artifact
39+
uses: actions/upload-artifact@v3
40+
with:
41+
name: linkcheck-output
42+
path: Doc/build/linkcheck/output.txt

0 commit comments

Comments
 (0)