actions: add eslint reviewdog

This commit is contained in:
Kavin 2023-07-27 12:57:43 +01:00
parent 301877e2e1
commit 590ad68513
No known key found for this signature in database
GPG Key ID: 6E4598CA5C92C41F

25
.github/workflows/reviewdog.yml vendored Normal file
View File

@ -0,0 +1,25 @@
name: reviewdog
on: [pull_request]
jobs:
eslint:
name: runner / eslint
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v3
- name: Setup pnpm
uses: pnpm/action-setup@v2
with:
version: latest
- name: Setup Node.js
uses: actions/setup-node@v3
with:
cache: "pnpm"
- run: pnpm install
- uses: reviewdog/action-eslint@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
reporter: github-pr-review
eslint_flags: "--ignore-path .gitignore --ext .js,.vue ."