Skip to content

Commit 01d0cbc

Browse files
yeying-xingchenPolardist
authored andcommitted
add: Markdown lint ci.
1 parent 23727fa commit 01d0cbc

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: MarkdownLint
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- '**/*.md'
7+
8+
jobs:
9+
lint:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v5
14+
with:
15+
fetch-depth: 0
16+
- name: Find change file
17+
uses: tj-actions/changed-files@v47
18+
id: changed-files
19+
with:
20+
files: '**/*.md'
21+
separator: ","
22+
- name: Lint Markdown files
23+
uses: DavidAnson/markdownlint-cli2-action@v20
24+
if: steps.changed-files.outputs.any_changed == 'true'
25+
with:
26+
globs: ${{ steps.changed-files.outputs.all_changed_files }}
27+
separator: ","

0 commit comments

Comments
 (0)