added a custom rubocop linter in order to avoid hardcoding application name
This commit is contained in:
parent
c1208add62
commit
03864f60cf
2 changed files with 29 additions and 0 deletions
12
.rubocop.yml
12
.rubocop.yml
|
@ -1,6 +1,7 @@
|
|||
require:
|
||||
- rubocop/rspec/focused
|
||||
- ./lib/cops/unscoped.rb
|
||||
- ./lib/cops/application_name.rb
|
||||
inherit_gem:
|
||||
rubocop-rails_config:
|
||||
- config/rails.yml
|
||||
|
@ -12,6 +13,17 @@ AllCops:
|
|||
- "bin/*"
|
||||
- "node_modules/**/*"
|
||||
|
||||
DS/Unscoped:
|
||||
Enabled: true
|
||||
|
||||
DS/ApplicationName:
|
||||
Enabled: true
|
||||
Exclude:
|
||||
- './config/application_name.rb'
|
||||
- './lib/cops/application_name.rb'
|
||||
- './lib/linters/application_name_linter.rb'
|
||||
- "./spec/**/*"
|
||||
|
||||
Bundler/DuplicatedGem:
|
||||
Enabled: true
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue