Skip to content

Commit b1b6a87

Browse files
committed
Use lychee to test links
1 parent 81fb2e2 commit b1b6a87

File tree

2 files changed

+33
-30
lines changed

2 files changed

+33
-30
lines changed
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: link-check
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
branches:
9+
- main
10+
schedule:
11+
- cron: '0 0 * * 0' # every Sunday at 00:00
12+
13+
jobs:
14+
linkChecker:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Link Checker
20+
id: lychee
21+
uses: lycheeverse/lychee-action@v1
22+
with:
23+
# fail action if there are broken links
24+
fail: true
25+
26+
- name: Create Issue From File
27+
# create issues only when triggered by schedule
28+
if: github.event_name == 'schedule' && env.lychee_exit_code != 0
29+
uses: peter-evans/create-issue-from-file@v5
30+
with:
31+
title: Link Checker Report
32+
content-filepath: ./lychee/out.md
33+
labels: report, automated issue

template/.mlc-config.json

Lines changed: 0 additions & 30 deletions
This file was deleted.

0 commit comments

Comments
 (0)