-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Problem ------- More dog-fooding. We want to promote the use of our carbonfive/c5-conventions rubocop file. Let's use it here. Solution -------- * Copy the carbonfive/c5-conventions `.rubocop.yml` into place * Remove `rubocop-performance` because we don't *really* need it and it'd require adding another gem dev depenency - seems overkill for it's possible benefit on *this* project * Add `lib/tasks` to `rakelib` * Add `rubocop.rake` file to get the `rubocop` and `rubocop:autocorrect` tasks * Run rubocop:autocorrect which cleaned a few things in bin/raygun NOTE ---- This repo is *still* not rubocop clean. There are several not-autofixable issues that could (should?) be addressed once this is approved.
- Loading branch information
Jon Rogers
committed
Jan 25, 2020
1 parent
c6fe3aa
commit 410c332
Showing
5 changed files
with
111 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
# Configuration hierarchy: | ||
# | ||
# 1. Rubocop defaults | ||
# 2. Carbon Five defaults (this file) | ||
# 3. Project overrides | ||
# | ||
# See http://rubocop.readthedocs.io/en/latest/configuration/#inheriting-configuration-from-a-remote-url for details. | ||
# | ||
|
||
AllCops: | ||
DisplayCopNames: true | ||
DisplayStyleGuide: true | ||
|
||
# | ||
# Ruby Cops | ||
# | ||
|
||
Layout/CaseIndentation: | ||
Enabled: false | ||
|
||
Layout/FirstArrayElementIndentation: | ||
EnforcedStyle: consistent | ||
|
||
Layout/HashAlignment: | ||
Enabled: false | ||
|
||
Layout/LineLength: | ||
Max: 120 | ||
|
||
Layout/MultilineMethodCallIndentation: | ||
EnforcedStyle: indented | ||
|
||
Lint/AmbiguousBlockAssociation: | ||
Enabled: false | ||
|
||
Lint/ScriptPermission: | ||
Exclude: | ||
- "Rakefile" | ||
|
||
Metrics/AbcSize: | ||
Max: 35 | ||
Exclude: | ||
- "spec/**/*" | ||
|
||
Metrics/BlockLength: | ||
CountComments: false | ||
Max: 50 | ||
Exclude: | ||
- "config/**/*" | ||
- "spec/**/*" | ||
|
||
Metrics/ClassLength: | ||
Max: 250 | ||
Exclude: | ||
- "spec/**/*" | ||
|
||
Metrics/MethodLength: | ||
Max: 25 | ||
Exclude: | ||
- "db/migrate/*" | ||
- "spec/**/*" | ||
|
||
Naming/PredicateName: | ||
Enabled: false | ||
|
||
Security/YAMLLoad: | ||
Enabled: false | ||
|
||
Style/BarePercentLiterals: | ||
EnforcedStyle: percent_q | ||
|
||
Style/BlockDelimiters: | ||
EnforcedStyle: braces_for_chaining | ||
|
||
Style/Documentation: | ||
Enabled: false | ||
|
||
Style/EmptyMethod: | ||
EnforcedStyle: expanded | ||
|
||
Style/FrozenStringLiteralComment: | ||
EnforcedStyle: never | ||
|
||
Style/Lambda: | ||
EnforcedStyle: literal | ||
|
||
Style/ModuleFunction: | ||
EnforcedStyle: extend_self | ||
|
||
Style/MutableConstant: | ||
Enabled: false | ||
|
||
Style/PreferredHashMethods: | ||
Enabled: false | ||
|
||
Style/StringLiterals: | ||
EnforcedStyle: double_quotes | ||
|
||
Style/StringLiteralsInInterpolation: | ||
EnforcedStyle: double_quotes | ||
|
||
Style/StructInheritance: | ||
Enabled: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
require "bundler/gem_tasks" | ||
Rake.add_rakelib "lib/tasks" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
require "rubocop/rake_task" | ||
|
||
RuboCop::RakeTask.new |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters