Skip to content

Commit

Permalink
Add rubocop github action step
Browse files Browse the repository at this point in the history
  • Loading branch information
jusleg committed Aug 13, 2020
1 parent e0b7b84 commit 89349f1
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 23 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/rubocop_lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Lint 💎

on: [push, pull_request]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Ruby 2.6 is
uses: actions/setup-ruby@v1
with:
ruby-version: 2.6.x
- uses: actions/cache@v1
with:
path: vendor/bundle
key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-gems-
- name: Run Rubocop linter
run: |
gem install bundler
bundle config path vendor/bundle
bundle install --jobs 4 --retry 3
bundle exec rubocop
25 changes: 2 additions & 23 deletions .rubocop-https---relaxed-ruby-style-rubocop-yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Relaxed.Ruby.Style
## Version 2.4
## Version 2.5

Style/Alias:
Enabled: false
Expand Down Expand Up @@ -145,30 +145,9 @@ Lint/AssignmentInCondition:
Enabled: false
StyleGuide: https://relaxed.ruby.style/#lintassignmentincondition

Metrics/AbcSize:
Enabled: false

Metrics/BlockNesting:
Enabled: false

Metrics/ClassLength:
Enabled: false

Metrics/ModuleLength:
Enabled: false

Metrics/CyclomaticComplexity:
Enabled: false

Layout/LineLength:
Enabled: false

Metrics/MethodLength:
Enabled: false

Metrics/ParameterLists:
Enabled: false

Metrics/PerceivedComplexity:
Metrics:
Enabled: false

3 changes: 3 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,6 @@ Style/ClassVars:

AllCops:
TargetRubyVersion: 2.6

Gemspec/RequiredRubyVersion:
Enabled: false

0 comments on commit 89349f1

Please sign in to comment.