Skip to content

Commit 777c1dd

Browse files
committed
Refactor RuboCop edge CI job
1 parent 2b55e6a commit 777c1dd

File tree

1 file changed

+19
-11
lines changed

1 file changed

+19
-11
lines changed

.github/workflows/main.yml

Lines changed: 19 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -32,22 +32,30 @@ jobs:
3232
task:
3333
- internal_investigation
3434
- spec
35-
rubocop_version:
36-
- gem
37-
include:
38-
- rubocop_version: edge
39-
ruby: 2.7
40-
task: internal_investigation
41-
- rubocop_version: edge
42-
ruby: 2.7
43-
task: spec
44-
name: ${{ matrix.task }}, Ruby ${{ matrix.ruby }} (${{ matrix.rubocop_version }})
35+
name: ${{ matrix.task }}, Ruby ${{ matrix.ruby }} (gem)
36+
steps:
37+
- uses: actions/checkout@v2
38+
- uses: ruby/setup-ruby@v1
39+
with:
40+
ruby-version: "${{ matrix.ruby }}"
41+
bundler-cache: true
42+
- run: bundle exec rake ${{ matrix.task }}
43+
44+
edge-rubocop:
45+
runs-on: ubuntu-latest
46+
strategy:
47+
matrix:
48+
ruby:
49+
- 2.7
50+
task:
51+
- internal_investigation
52+
- spec
53+
name: ${{ matrix.task }} Ruby ${{ matrix.ruby }} (edge)
4554
steps:
4655
- uses: actions/checkout@v2
4756
- name: Use latest RuboCop from `master`
4857
run: |
4958
echo "gem 'rubocop', github: 'rubocop-hq/rubocop'" > Gemfile.local
50-
if: matrix.rubocop_version == 'edge'
5159
- uses: ruby/setup-ruby@v1
5260
with:
5361
ruby-version: "${{ matrix.ruby }}"

0 commit comments

Comments
 (0)