Fix members #10
Workflow file for this run
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: Check links | |
| # Catches broken links before they reach master. Two layers: | |
| # 1. `mkdocs build --strict` fails on broken internal links and missing | |
| # navigation targets. | |
| # 2. lychee checks external (http/https) links in the docs and mkdocs.yml. | |
| # Hosts that require a login or block automated requests are listed in | |
| # .lycheeignore. Publishers and doi.org commonly return 403/429 to bots even | |
| # for valid links, so those codes (plus transient 503) are accepted; genuine | |
| # 404s, dead domains, and connection errors still fail the build. | |
| on: | |
| push: | |
| pull_request: | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| jobs: | |
| links: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.x' | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install -r requirements.txt | |
| - name: Build site (fails on broken internal links and nav) | |
| run: mkdocs build --strict | |
| - name: Check external links | |
| uses: lycheeverse/lychee-action@v2 | |
| with: | |
| args: >- | |
| --no-progress | |
| --scheme http | |
| --scheme https | |
| --accept 200,206,403,429,503 | |
| --max-retries 2 | |
| "docs/**/*.md" | |
| "mkdocs.yml" | |
| fail: true | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |