-
Notifications
You must be signed in to change notification settings - Fork 18
46 lines (40 loc) · 1.09 KB
/
code-style-review.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
46
name: "Code Style Review"
on:
pull_request:
branches:
- "master"
paths-ignore:
- "doc/**"
- "**.md"
jobs:
lint:
runs-on: "ubuntu-latest"
steps:
- name: "Checkout"
uses: actions/checkout@v4
- name: "Set up Ruby"
uses: ruby/setup-ruby@v1
with:
ruby-version: 2.7
- name: "Rubocop"
uses: reviewdog/action-rubocop@v2
with:
rubocop_version: gemfile
rubocop_extensions: rubocop-minitest:gemfile rubocop-performance:gemfile rubocop-rails:gemfile
reporter: github-pr-review
level: error
- name: "Install HAML-Lint"
run: "gem install haml-lint"
- name: "Set up reviewdog"
uses: reviewdog/action-setup@v1
- name: "Run reviewdog HAML-Lint"
env:
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
haml-lint |
reviewdog \
-efm="%f:%l %m" \
-name="Haml-lint" \
-reporter=github-pr-review \
-level=error \
-diff="git diff $DIFF_BRANCH"