-
Notifications
You must be signed in to change notification settings - Fork 14
44 lines (37 loc) · 908 Bytes
/
check-links.yml
File metadata and controls
44 lines (37 loc) · 908 Bytes
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
name: Check Links
on:
push:
branches:
- master
- main
pull_request:
branches:
- master
- main
schedule:
# Run weekly on Monday at 9am UTC to catch links that go dead over time
- cron: '0 9 * * 1'
workflow_dispatch:
jobs:
link-check:
name: Check Links with htmltest
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Hugo
uses: peaceiris/actions-hugo@v3
with:
hugo-version: '0.147.0'
extended: true
- name: Build site
run: hugo --gc --minify --buildFuture
- name: Check links
run: ./check-links.sh
- name: Archive htmltest results
if: failure()
uses: actions/upload-artifact@v4
with:
name: htmltest-report
path: tmp/.htmltest/
retention-days: 7