Lychee link checker #24
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| name: Lychee link checker | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| # Run weekly on Sundays at 3 AM UTC to catch broken links | |
| - cron: '0 3 * * 0' | |
| permissions: | |
| contents: read | |
| jobs: | |
| link-checker: | |
| name: Lychee link checker | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| python-version: '3.12' | |
| enable-cache: true | |
| cache-dependency-glob: "**/pyproject.toml" | |
| - name: Create virtual environment | |
| run: | | |
| uv venv --clear .venv | |
| echo "$GITHUB_WORKSPACE/.venv/bin" >> $GITHUB_PATH | |
| - name: Install dependencies | |
| run: uv pip install ".[docs]" | |
| - name: Build documentation with Sphinx | |
| run: | | |
| sphinx-build -b html docs docs/_build/html | |
| - name: Link Checker | |
| id: lychee | |
| uses: lycheeverse/lychee-action@v2.8.0 | |
| with: | |
| args: --config lychee.toml --verbose --no-progress --max-redirects 10 'docs/_build/html/**/*.html' README.md RELEASE_GUIDE.md CONTRIBUTING.md | |
| fail: true |