-
Notifications
You must be signed in to change notification settings - Fork 84
45 lines (43 loc) · 1.07 KB
/
check-doc.yaml
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
34
35
36
37
38
39
40
41
42
43
44
45
name: Check document
on:
push:
branches: [master]
paths:
- 'docs/**'
- 'package.json'
- '.autocorrectrc'
- '.markdownlint-cli2.jsonc'
- '.github/workflows/check-doc.yaml'
pull_request:
branches: [master]
paths:
- 'docs/**'
- 'package.json'
- '.autocorrectrc'
- '.markdownlint-cli2.jsonc'
- '.github/workflows/check-doc.yaml'
jobs:
check-doc:
name: Check document
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version: '16.x'
cache: 'npm'
- name: Install dependencies
run: |
npm ci
- name: Lint Markdown files (markdownlint)
run: |
npm run markdown-lint
- name: Lint Markdown files (autocorrect)
uses: huacnlee/autocorrect-action@main
with:
args: --lint ./docs/
- name: Check broken link (including broken anchor)
run: |
npm run check-broken-link