Skip to content

Commit edfc2c1

Browse files
committed
add link checker action
1 parent eb1ebc4 commit edfc2c1

1 file changed

Lines changed: 31 additions & 0 deletions

File tree

.github/workflows/lychee.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Lychee-Checker
2+
3+
on:
4+
schedule:
5+
- cron: "0 0 1 * *"
6+
7+
jobs:
8+
linkChecker:
9+
name: Lychee Link Checker
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v3
14+
15+
- name: Check Links
16+
id: lychee
17+
uses: lycheeverse/lychee-action@v1.5.1
18+
with:
19+
args: --verbose --max-concurrency 32 --timeout 120 --no-progress *.md
20+
21+
- name: Create Issue From File
22+
if: ${{ steps.lychee.outputs.exit_code != 0 }}
23+
uses: peter-evans/create-issue-from-file@v4
24+
with:
25+
title: Link Checker Report
26+
content-filepath: ./lychee/out.md
27+
labels: report, automated issue
28+
29+
- name: Fail if there were link errors
30+
if: ${{ steps.lychee.outputs.exit_code != 0 }}
31+
run: exit ${{ steps.lychee.outputs.exit_code }}

0 commit comments

Comments
 (0)