-
Notifications
You must be signed in to change notification settings - Fork 42
31 lines (29 loc) · 980 Bytes
/
textlint.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
name: Textlint
on: [pull_request]
jobs:
lint:
name: Textlint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '12.x'
- run: npm ci
- name: Setup reviewdog
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
run: |
mkdir -p $HOME/bin && curl -sfL https://raw.githubusercontent.com/reviewdog/reviewdog/master/install.sh| sh -s -- -b $HOME/bin
echo ::add-path::$HOME/bin
echo ::add-path::$(go env GOPATH)/bin # for Go projects
- name: Run textlint
env:
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
npx textlint -f checkstyle "src/**/*.md" \
| reviewdog -reporter=github-pr-check \
-f=checkstyle \
-name="textlint" \
-level="${INPUT_LEVEL:-'error'}"