From 18ee352a95b958dd0990da50d0f2cdce857f62c6 Mon Sep 17 00:00:00 2001 From: Andy Brody Date: Fri, 28 Nov 2014 00:25:39 -0500 Subject: [PATCH] Add rubocop configuration. --- .rubocop-disables.yml | 352 ++++++++++++++++++++++++++++++++++++++++++ .rubocop.yml | 3 + 2 files changed, 355 insertions(+) create mode 100644 .rubocop-disables.yml create mode 100644 .rubocop.yml diff --git a/.rubocop-disables.yml b/.rubocop-disables.yml new file mode 100644 index 0000000..dca8f5a --- /dev/null +++ b/.rubocop-disables.yml @@ -0,0 +1,352 @@ +# This configuration was generated by `rubocop --auto-gen-config` +# on 2014-07-08 08:57:44 +0000 using RuboCop version 0.24.1. +# The point is for the user to remove these configuration records +# one by one as the offenses are removed from the code base. +# Note that changes in the inspected code, or installation of new +# versions of RuboCop, may require this file to be generated again. + +# TODO +# Offense count: 1 +# Cop supports --auto-correct. +Lint/StringConversionInInterpolation: + Enabled: false + +# Tests only +# Offense count: 16 +# Cop supports --auto-correct. +Lint/UnusedBlockArgument: + Enabled: false + +# Offense count: 4 +# Cop supports --auto-correct. +Style/Alias: + Enabled: false + +# TODO +# Offense count: 3 +# Cop supports --auto-correct. +Style/AndOr: + Enabled: false + +# TODO +# Offense count: 3 +# Cop supports --auto-correct. +Style/Blocks: + Enabled: false + +# Offense count: 48 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/BracesAroundHashParameters: + Enabled: false + +# Offense count: 1 +Style/ClassAndModuleCamelCase: + Enabled: false + +# Offense count: 2 +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/ClassAndModuleChildren: + Enabled: false + +# Offense count: 1 +# Configuration parameters: CountComments. +Metrics/ClassLength: + Max: 411 + +# TODO +# Offense count: 5 +Style/ClassVars: + Enabled: false + +# TODO +# Offense count: 5 +# Cop supports --auto-correct. +# Configuration parameters: PreferredMethods. +Style/CollectionMethods: + Enabled: false + +# TODO +# Offense count: 4 +# Cop supports --auto-correct. +Style/ColonMethodCall: + Enabled: false + +# Offense count: 2 +Style/ConstantName: + Enabled: false + +# TODO: eh? +# Offense count: 4 +Metrics/CyclomaticComplexity: + Max: 22 + +# Offense count: 1 +# Cop supports --auto-correct. +Style/DeprecatedHashMethods: + Enabled: false + +# TODO: docs +# Offense count: 17 +Style/Documentation: + Enabled: false + +# Offense count: 9 +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/DotPosition: + Enabled: false + +# Offense count: 1 +Style/DoubleNegation: + Enabled: false + +# TODO +# Offense count: 2 +Style/EachWithObject: + Enabled: false + +# Offense count: 11 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/EmptyLinesAroundClassBody: + Enabled: false + +# Offense count: 1 +# Cop supports --auto-correct. +Style/EmptyLinesAroundMethodBody: + Enabled: false + +# Offense count: 9 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/EmptyLinesAroundModuleBody: + Enabled: false + +# Offense count: 31 +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/Encoding: + Enabled: false + +# TODO: exclude +# Offense count: 1 +# Configuration parameters: Exclude. +Style/FileName: + Enabled: false + +# Offense count: 3 +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/FormatString: + Enabled: false + +# TODO: configure +# Offense count: 514 +# Cop supports --auto-correct. +# Configuration parameters: SupportedStyles. +Style/HashSyntax: + EnforcedStyle: hash_rockets + +# NOTABUG +# Offense count: 8 +# Configuration parameters: MaxLineLength. +Style/IfUnlessModifier: + Enabled: false + +# TODO: configure +# Offense count: 6 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/IndentHash: + Enabled: false + +# NOTABUG +# Offense count: 19 +Style/Lambda: + Enabled: false + +# TODO +# Offense count: 14 +# Cop supports --auto-correct. +Style/LeadingCommentSpace: + Enabled: false + +# TODO +# Offense count: 218 +# Configuration parameters: AllowURI. +Metrics/LineLength: + Max: 340 + +# TODO +# Offense count: 28 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/MethodDefParentheses: + Enabled: false + +# TODO +# Offense count: 1 +Style/ModuleFunction: + Enabled: false + +# Offense count: 4 +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/Next: + Enabled: false + +# Offense count: 1 +# Cop supports --auto-correct. +# Configuration parameters: IncludeSemanticChanges. +Style/NonNilCheck: + Enabled: false + +# TODO: exclude +# Offense count: 1 +# Cop supports --auto-correct. +Style/Not: + Enabled: false + +# Offense count: 2 +# Cop supports --auto-correct. +Style/NumericLiterals: + MinDigits: 11 + +# TODO? +# Offense count: 1 +# Cop supports --auto-correct. +# Configuration parameters: AllowSafeAssignment. +Style/ParenthesesAroundCondition: + Enabled: false + +# Offense count: 8 +# Cop supports --auto-correct. +# Configuration parameters: PreferredDelimiters. +Style/PercentLiteralDelimiters: + PreferredDelimiters: + '%w': '{}' + '%W': '{}' + '%Q': '{}' + Exclude: + - 'bin/restclient' + +# Offense count: 3 +# Configuration parameters: NamePrefixBlacklist. +Style/PredicateName: + Enabled: false + +# TODO: configure +# Offense count: 3 +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/RaiseArgs: + Enabled: false + +# TODO +# Offense count: 1 +# Cop supports --auto-correct. +Style/RedundantBegin: + Enabled: false + +# Offense count: 2 +# Cop supports --auto-correct. +Style/RedundantSelf: + Enabled: false + +# Offense count: 1 +Style/RescueModifier: + Enabled: false + Exclude: + - 'bin/restclient' + +# TODO: configure +# Offense count: 12 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/SignalException: + Enabled: false + +# TODO +# Offense count: 2 +# Cop supports --auto-correct. +Style/SpaceAfterNot: + Enabled: false + +# Offense count: 19 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/SpaceAroundEqualsInParameterDefault: + Enabled: false + +# Offense count: 20 +# Cop supports --auto-correct. +Style/SpaceAroundOperators: + Enabled: false + +# Offense count: 9 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/SpaceBeforeBlockBraces: + Enabled: false + +# Offense count: 37 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles, EnforcedStyleForEmptyBraces, SpaceBeforeBlockParameters. +Style/SpaceInsideBlockBraces: + Enabled: false + +# Offense count: 6 +# Cop supports --auto-correct. +Style/SpaceInsideBrackets: + Enabled: false + +# Offense count: 181 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBraces, SupportedStyles. +Style/SpaceInsideHashLiteralBraces: + Enabled: false + +# TODO +# Offense count: 9 +# Cop supports --auto-correct. +Style/SpaceInsideParens: + Enabled: false + +# Offense count: 414 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/StringLiterals: + Enabled: false + +# NOTABUG +# Offense count: 14 +# Configuration parameters: EnforcedStyleForMultiline, SupportedStyles. +Style/TrailingComma: + Enabled: false + +# TODO: configure +# Offense count: 1 +# Cop supports --auto-correct. +# Configuration parameters: ExactNameMatch, AllowPredicates, AllowDSLWriters, Whitelist. +Style/TrivialAccessors: + Enabled: false + Exclude: ['lib/restclient/payload.rb'] + +# TODO? +# Offense count: 3 +Style/UnlessElse: + Enabled: false + +# TODO? +# Offense count: 6 +# Cop supports --auto-correct. +Style/UnneededPercentQ: + Enabled: false + +# Offense count: 5 +# Cop supports --auto-correct. +Style/WordArray: + MinSize: 4 + +# TODO? +# Offense count: 5 +# Cop supports --auto-correct. +# Configuration parameters: EnforcedStyle, SupportedStyles. +Style/BarePercentLiterals: + Enabled: false diff --git a/.rubocop.yml b/.rubocop.yml new file mode 100644 index 0000000..4a11243 --- /dev/null +++ b/.rubocop.yml @@ -0,0 +1,3 @@ +--- +inherit_from: +- .rubocop-disables.yml