Lint the recent changes (#219) #317
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: Lint Markdown and check links | |
| on: | |
| pull_request: | |
| branches: | |
| - main | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| check-links: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '18' | |
| - name: Install Dependencies | |
| run: | | |
| npm install | |
| npm install -g markdownlint-cli | |
| npm install -g markdown-link-check | |
| - name: Lint markdown | |
| run: npm run lint | |
| - name: Check Table of Contents | |
| run: npm run check-toc | |
| - name: Link check | |
| uses: nick-fields/retry@v3 | |
| with: | |
| timeout_minutes: 10 | |
| max_attempts: 3 | |
| command: npm run links-ci |