Skip to content

Commit 1730e55

Browse files
TC-MOB4nan
andauthored
feat: change link checking to periodic (#1140)
Given the amount of false positives we run into at every time when we are adding a new page to docs, it makes sense to change the link checking job to periodic instead of at every PR. --------- Co-authored-by: Martin Adámek <[email protected]>
1 parent 31b2f87 commit 1730e55

File tree

1 file changed

+24
-5
lines changed

1 file changed

+24
-5
lines changed

.github/workflows/lychee.yml

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1-
name: Lychee Link Checker
1+
name: Periodic Link Checker
22

3-
on: [ pull_request ]
3+
on:
4+
schedule:
5+
- cron: '0 0 * * *' # Run daily at midnight UTC
6+
workflow_dispatch: # Allow manual triggering
47

58
jobs:
69
link-check:
@@ -28,9 +31,25 @@ jobs:
2831
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2932
SMARTLOOK_PROJECT_KEY: ${{ secrets.SMARTLOOK_PROJECT_KEY }}
3033

31-
- uses: lycheeverse/[email protected]
34+
- name: Run Lychee Link Checker
35+
id: lychee
36+
uses: lycheeverse/[email protected]
3237
env:
3338
GITHUB_TOKEN: ${{ secrets.APIFY_SERVICE_ACCOUNT_GITHUB_TOKEN }}
3439
with:
35-
fail: true
36-
args: --base https://docs.apify.com --exclude-path 'build/versions.html' --max-retries 6 --verbose --no-progress --accept '100..=103,200..=299,403..=403, 429' './build/**/*.html'
40+
fail: false
41+
args: >
42+
--base https://docs.apify.com
43+
--exclude-path 'build/versions.html'
44+
--max-retries 6
45+
--verbose
46+
--no-progress
47+
--accept '100..=103,200..=299,403..=403,429'
48+
--output ./lychee/out.md
49+
--format markdown
50+
'./build/**/*.html'
51+
continue-on-error: true
52+
53+
- name: Add job summary
54+
if: always()
55+
run: cat ./lychee/out.md >> $GITHUB_STEP_SUMMARY

0 commit comments

Comments
 (0)