Skip to content

linkcheck

linkcheck #7

Workflow file for this run

name: linkcheck
# Verify that every [](url) link in the Markdown sources resolves with a good
# status code. Runs on PRs and pushes to main, plus weekly to catch link rot.
on:
push:
branches: [main]
pull_request:
schedule:
- cron: "0 6 * * 1"
workflow_dispatch:
permissions:
contents: read
concurrency:
group: linkcheck-${{ github.ref }}
cancel-in-progress: true
jobs:
markdown-links:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check all Markdown links
uses: lycheeverse/lychee-action@v2
with:
args: >-
--config lychee.toml --no-progress
--exclude-path node_modules --exclude-path site
"**/*.md"
fail: true
# A repo state with no links in its Markdown is legitimate (the
# skeleton README has none); only broken links should fail the job.
failIfEmpty: false
env:
# Authenticated GitHub requests avoid api.github.com / github.com rate limits.
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}