-
Notifications
You must be signed in to change notification settings - Fork 5
37 lines (32 loc) · 909 Bytes
/
link_check.yml
File metadata and controls
37 lines (32 loc) · 909 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
name: Link Checker
on:
workflow_dispatch:
schedule:
- cron: "00 9 * * *"
push:
branches:
- main
merge_group:
pull_request:
branches:
- main
jobs:
linkChecker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Link Checker
id: lychee
uses: lycheeverse/lychee-action@v2
with:
args: --verbose --user-agent "curl/8.5.0" --no-progress './**/*.md' './**/*.html' './**/*.rst' './**/*.tsx'
- name: Create Issue From File
if: env.lychee_exit_code != 0 && github.event_name == 'schedule'
uses: peter-evans/create-issue-from-file@v6
with:
title: Link Checker Report
content-filepath: ./lychee/out.md
labels: automated issue
- name: Fail job on error
if: env.lychee_exit_code != 0 && github.event_name != 'schedule'
run: exit 1