Skip to content

chore(ci): restrict what and when to check with lychee to avoid rate limiting #41

chore(ci): restrict what and when to check with lychee to avoid rate limiting

chore(ci): restrict what and when to check with lychee to avoid rate limiting #41

---
name: Check Links Quickly
"on":
push:
branches:
- main
- dev
paths:
- .github/workflows/check-links-quickly.yaml
- docs/**.md
pull_request:
paths:
- .github/workflows/check-links-quickly.yaml
- docs/**.md
jobs:
linkChecker:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Restore lychee cache
id: restore-cache
uses: actions/cache/restore@v3
with:
path: .lycheecache
key: cache-lychee-${{ github.sha }}
restore-keys: cache-lychee-
- name: Run lychee
uses: lycheeverse/[email protected]
with:
fail: true
args: "--base . --verbose --no-progress --cache --max-cache-age 3d 'docs/**/*.md'"
- name: Save lychee cache
uses: actions/cache/save@v3
if: always()
with:
path: .lycheecache
key: ${{ steps.restore-cache.outputs.cache-primary-key }}