additionals/.rubocop.yml

142 lines
2.3 KiB
YAML
Raw Normal View History

require:
- rubocop-performance
- rubocop-rails
2022-04-11 16:12:56 +02:00
- rubocop-minitest
AllCops:
TargetRubyVersion: 2.7
2022-04-10 13:45:24 +02:00
TargetRailsVersion: 6.1
2020-04-16 13:00:07 +02:00
NewCops: enable
2022-04-11 16:12:56 +02:00
Rails:
Enabled: true
Minitest/MultipleAssertions:
Max: 15
Enabled: true
Minitest/AssertPredicate:
Enabled: false
Metrics/AbcSize:
2019-12-25 08:45:16 +01:00
Enabled: false
Metrics/BlockLength:
2019-12-25 08:45:16 +01:00
Enabled: false
Metrics/ParameterLists:
Enabled: true
CountKeywordArgs: false
Metrics/ClassLength:
Enabled: false
Metrics/CyclomaticComplexity:
2020-09-25 10:42:03 +02:00
Max: 25
2021-03-24 08:08:17 +01:00
Style/HashConversion:
Enabled: true
Layout/LineLength:
2015-10-09 18:20:04 +02:00
Max: 140
Metrics/MethodLength:
Max: 60
Metrics/ModuleLength:
Enabled: false
2015-12-06 12:48:33 +01:00
2015-10-09 18:20:04 +02:00
Metrics/PerceivedComplexity:
2018-11-17 08:18:46 +01:00
Max: 25
2015-10-09 18:20:04 +02:00
Rails/ApplicationJob:
Enabled: false
2021-09-14 19:58:08 +02:00
Lint/AmbiguousOperatorPrecedence:
Enabled: false
Rails/ApplicationRecord:
2015-10-10 14:11:02 +02:00
Enabled: false
Rails/CreateTableWithTimestamps:
Enabled: false
Rails/HelperInstanceVariable:
Enabled: false
Rails/SkipsModelValidations:
Enabled: false
Rails/Output:
Enabled: true
Exclude:
- 'db/migrate/*'
Performance/ChainArrayAllocation:
Enabled: true
Style/AutoResourceCleanup:
Enabled: true
2016-10-19 13:30:14 +02:00
Style/ExpandPathArguments:
Enabled: true
Exclude:
- additionals.gemspec
- test/**/*
Style/FrozenStringLiteralComment:
Enabled: true
Exclude:
- '/**/*.rsb'
Style/OptionHash:
Enabled: true
SuspiciousParamNames:
- options
- api_options
- opts
- args
- params
- parameters
- settings
Exclude:
- lib/additionals/patches/*.rb
2018-07-15 10:07:31 +02:00
# postgresql and mysql are supported
# autodetect does not work without database configuration
Rails/BulkChangeTable:
Enabled: true
Database: postgresql
Style/ReturnNil:
Enabled: true
Style/UnlessLogicalOperators:
Enabled: true
Style/MethodCallWithArgsParentheses:
Enabled: true
AllowParenthesesInMultilineCall: true
AllowParenthesesInChaining: true
EnforcedStyle: omit_parentheses
Style/Documentation:
2018-07-15 10:07:31 +02:00
Enabled: false
2020-03-09 14:51:54 +01:00
Style/HashTransformValues:
Enabled: false
Naming/VariableNumber:
2020-12-25 13:31:19 +01:00
Enabled: true
Exclude:
- 'test/**/*'
2020-12-01 12:01:34 +01:00
Style/StringConcatenation:
Exclude:
- 'app/views/additionals/_select2_ajax_call.*'
# see https://github.com/rubocop/rubocop-rails/issues/578
# redmine does not use load_defaults: https://rails.rubystyle.guide/#config-defaults
Rails/RedundantPresenceValidationOnBelongsTo:
Enabled: false