-
Notifications
You must be signed in to change notification settings - Fork 8
33 lines (30 loc) · 1.01 KB
/
markdown-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Lint and Check Markdown
on:
pull_request:
branches:
- main
paths:
- 'docs/**'
- '**.md'
- '**.markdown'
- '.markdownlint.jsonc'
- '.markdownlinkcheck.json'
jobs:
lint-markdown:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- run: |
npm install markdownlint-cli
- run: |
node_modules/.bin/markdownlint -c .markdownlint.jsonc -i node_modules/ .
markdown-link-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: |
# markdown-link-check had a regression introduced in version 3.12.0. Keep it at 3.11.2 until that is resolved
# Issue: https://github.com/tcort/markdown-link-check/issues/304
npm install [email protected]
find . -type d \( -name node_modules -o -name .github \) -prune -o -type f -name '*.md' -print0 | xargs -0 -n1 node_modules/.bin/markdown-link-check --config .markdownlinkcheck.json --quiet