summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Graaff <graaff@gentoo.org>2019-07-23 23:31:02 +0200
committerHans de Graaff <graaff@gentoo.org>2019-07-23 23:31:02 +0200
commit4a200e21412007150148ac79f059bb65d931478a (patch)
treef83e166af85f28acb7fa9d7e0c7f1ea6f7faecb6
parentFix tests to account for changes in the code (diff)
downloadglsamaker-4a200e21412007150148ac79f059bb65d931478a.tar.gz
glsamaker-4a200e21412007150148ac79f059bb65d931478a.tar.bz2
glsamaker-4a200e21412007150148ac79f059bb65d931478a.zip
Update rubocop configuration
Add performance and rails plugins, and generate a todo file so that rubocop is "green". This also updates some dependencies in the Gemfile.lock file. Signed-off-by: Hans de Graaff <graaff@gentoo.org>
-rw-r--r--.rubocop.yml22
-rw-r--r--.rubocop_todo.yml1376
-rw-r--r--Gemfile4
-rw-r--r--Gemfile.lock60
4 files changed, 1433 insertions, 29 deletions
diff --git a/.rubocop.yml b/.rubocop.yml
index 2be5ee8..d379a78 100644
--- a/.rubocop.yml
+++ b/.rubocop.yml
@@ -1,3 +1,16 @@
+inherit_from: .rubocop_todo.yml
+
+require:
+ - rubocop-performance
+ - rubocop-rails
+
+AllCops:
+ TargetRubyVersion: 2.4
+ TargetRailsVersion: 4.2
+
+Rails:
+ Enabled: true
+
Style/AsciiComments:
Enabled: false
@@ -10,14 +23,5 @@ Style/Documentation:
Style/PerlBackrefs:
Enabled: false
-Metrics/LineLength:
- Max: 120
-
-Metrics/MethodLength:
- Max: 20
-
Metrics/ModuleLength:
Max: 200
-
-Metrics/AbcSize:
- Max: 50
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml
new file mode 100644
index 0000000..b3272d9
--- /dev/null
+++ b/.rubocop_todo.yml
@@ -0,0 +1,1376 @@
+# This configuration was generated by
+# `rubocop --auto-gen-config`
+# on 2019-07-23 23:27:07 +0200 using RuboCop version 0.73.0.
+# 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.
+
+# Offense count: 7
+# Cop supports --auto-correct.
+# Configuration parameters: TreatCommentsAsGroupSeparators, Include.
+# Include: **/*.gemfile, **/Gemfile, **/gems.rb
+Bundler/OrderedGems:
+ Exclude:
+ - 'Gemfile'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, IndentationWidth.
+# SupportedStyles: outdent, indent
+Layout/AccessModifierIndentation:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Layout/AlignArray:
+ Exclude:
+ - 'lib/glsamaker/bugs.rb'
+
+# Offense count: 22
+# Cop supports --auto-correct.
+# Configuration parameters: AllowMultipleStyles, EnforcedHashRocketStyle, EnforcedColonStyle, EnforcedLastArgumentHashStyle.
+# SupportedHashRocketStyles: key, separator, table
+# SupportedColonStyles: key, separator, table
+# SupportedLastArgumentHashStyles: always_inspect, always_ignore, ignore_implicit, ignore_explicit
+Layout/AlignHash:
+ Exclude:
+ - 'app/mailers/glsa_mailer.rb'
+ - 'app/models/package.rb'
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'lib/glsamaker/portage.rb'
+ - 'lib/tasks/cve.rake'
+ - 'test/unit/user_test.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/BlockEndNewline:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+
+# Offense count: 11
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, IndentOneStep, IndentationWidth.
+# SupportedStyles: case, end
+Layout/CaseIndentation:
+ Exclude:
+ - 'lib/tasks/rcov.rake'
+ - 'test/test_helper.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Layout/ClosingParenthesisIndentation:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/application_helper.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/CommentIndentation:
+ Exclude:
+ - 'Gemfile'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: leading, trailing
+Layout/DotPosition:
+ Exclude:
+ - 'app/helpers/application_helper.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/ElseAlignment:
+ Exclude:
+ - 'app/views/glsa/_glsa.xml.builder'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: AllowBorderComment, AllowMarginComment.
+Layout/EmptyComment:
+ Exclude:
+ - 'config/routes.rb'
+
+# Offense count: 16
+# Cop supports --auto-correct.
+Layout/EmptyLineAfterGuardClause:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'lib/glsamaker/portage.rb'
+ - 'test/test_helper.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/EmptyLineAfterMagicComment:
+ Exclude:
+ - 'db/schema.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: AllowAdjacentOneLineDefs, NumberOfEmptyLines.
+Layout/EmptyLineBetweenDefs:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/EmptyLines:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+
+# Offense count: 14
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: around, only_before
+Layout/EmptyLinesAroundAccessModifier:
+ Exclude:
+ - 'app/controllers/application_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/glsa_helper.rb'
+ - 'lib/authentication.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/glsamaker/helpers.rb'
+ - 'lib/glsamaker/mail.rb'
+ - 'lib/glsamaker/portage.rb'
+ - 'lib/glsamaker/xml.rb'
+ - 'lib/tasks/utils.rb'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: empty_lines, no_empty_lines
+Layout/EmptyLinesAroundBlockBody:
+ Exclude:
+ - 'config/environments/production.rb'
+ - 'config/routes.rb'
+ - 'db/schema.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines, beginning_only, ending_only
+Layout/EmptyLinesAroundClassBody:
+ Exclude:
+ - 'app/controllers/bug_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'lib/glsamaker/bugs.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Layout/EmptyLinesAroundMethodBody:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'lib/bugzilla.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: empty_lines, empty_lines_except_namespace, empty_lines_special, no_empty_lines
+Layout/EmptyLinesAroundModuleBody:
+ Exclude:
+ - 'lib/glsamaker/diff.rb'
+ - 'lib/glsamaker/mail.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyleAlignWith, AutoCorrect, Severity.
+# SupportedStylesAlignWith: keyword, variable, start_of_line
+Layout/EndAlignment:
+ Exclude:
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 18
+# Cop supports --auto-correct.
+# Configuration parameters: AllowForAlignment, AllowBeforeTrailingComments, ForceEqualSignAlignment.
+Layout/ExtraSpacing:
+ Exclude:
+ - 'app/controllers/comments_controller.rb'
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/views/cve/info.json.jbuilder'
+ - 'bin/setup'
+ - 'config.ru'
+ - 'db/schema.rb'
+ - 'script/db-backup'
+ - 'script/rails'
+
+# Offense count: 4
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, IndentationWidth.
+# SupportedStyles: consistent, consistent_relative_to_receiver, special_for_inner_method_call, special_for_inner_method_call_in_parentheses
+Layout/IndentFirstArgument:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/application_helper.rb'
+ - 'app/helpers/glsa_helper.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+# Configuration parameters: IndentationWidth.
+# SupportedStyles: special_inside_parentheses, consistent, align_brackets
+Layout/IndentFirstArrayElement:
+ EnforcedStyle: consistent
+
+# Offense count: 7
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, IndentationWidth.
+# SupportedStyles: special_inside_parentheses, consistent, align_braces
+Layout/IndentFirstHashElement:
+ Exclude:
+ - 'app/models/package.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: normal, indented_internal_methods
+Layout/IndentationConsistency:
+ Exclude:
+ - 'app/models/glsa.rb'
+ - 'lib/authentication.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 25
+# Cop supports --auto-correct.
+# Configuration parameters: Width, IgnoredPatterns.
+Layout/IndentationWidth:
+ Exclude:
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'db/migrate/20100814103856_create_cve_references.rb'
+ - 'lib/authentication.rb'
+ - 'lib/glsamaker/spelling.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 31
+# Cop supports --auto-correct.
+# Configuration parameters: AllowDoxygenCommentStyle.
+Layout/LeadingCommentSpace:
+ Exclude:
+ - 'Gemfile'
+ - 'app/controllers/application_controller.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/glsamaker.rb'
+ - 'lib/tasks/import.rake'
+ - 'script/db-backup'
+ - 'test/unit/revision_test.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: symmetrical, new_line, same_line
+Layout/MultilineMethodCallBraceLayout:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, IndentationWidth.
+# SupportedStyles: aligned, indented, indented_relative_to_receiver
+Layout/MultilineMethodCallIndentation:
+ Exclude:
+ - 'app/helpers/application_helper.rb'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, IndentationWidth.
+# SupportedStyles: aligned, indented
+Layout/MultilineOperationIndentation:
+ Exclude:
+ - 'db/migrate/20100918223549_add_system_user.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/RescueEnsureAlignment:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+Layout/SpaceAfterComma:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+ - 'config/deploy.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyleInsidePipes.
+# SupportedStylesInsidePipes: space, no_space
+Layout/SpaceAroundBlockParameters:
+ Exclude:
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 11
+# Cop supports --auto-correct.
+# Configuration parameters: AllowForAlignment.
+Layout/SpaceAroundOperators:
+ Exclude:
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/cve.rb'
+ - 'app/models/package.rb'
+ - 'script/db-backup'
+
+# Offense count: 22
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBraces.
+# SupportedStyles: space, no_space
+# SupportedStylesForEmptyBraces: space, no_space
+Layout/SpaceBeforeBlockBraces:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/helpers/admin/templates_helper.rb'
+ - 'app/helpers/admin/users_helper.rb'
+ - 'lib/tasks/rcov.rake'
+ - 'test/unit/glsa_test.rb'
+ - 'test/unit/revision_test.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Layout/SpaceBeforeComma:
+ Exclude:
+ - 'config/routes.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+Layout/SpaceBeforeSemicolon:
+ Exclude:
+ - 'config/deploy.rb'
+ - 'lib/bugzilla.rb'
+
+# Offense count: 72
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBraces, SpaceBeforeBlockParameters.
+# SupportedStyles: space, no_space
+# SupportedStylesForEmptyBraces: space, no_space
+Layout/SpaceInsideBlockBraces:
+ Enabled: false
+
+# Offense count: 67
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBraces.
+# SupportedStyles: space, no_space, compact
+# SupportedStylesForEmptyBraces: space, no_space
+Layout/SpaceInsideHashLiteralBraces:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/index_controller.rb'
+ - 'app/controllers/tools_controller.rb'
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/comment.rb'
+ - 'app/models/glsa.rb'
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'config/deploy.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/glsamaker/http.rb'
+ - 'lib/glsamaker/xml.rb'
+ - 'test/test_helper.rb'
+ - 'test/unit/glsa_test.rb'
+
+# Offense count: 8
+# Cop supports --auto-correct.
+Layout/SpaceInsidePercentLiteralDelimiters:
+ Exclude:
+ - 'config/application.rb'
+ - 'config/initializers/glsamaker-global.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 7
+# Cop supports --auto-correct.
+# Configuration parameters: IndentationWidth.
+Layout/Tab:
+ Exclude:
+ - 'app/views/glsa/_glsa.xml.builder'
+
+# Offense count: 22
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: final_newline, final_blank_line
+Layout/TrailingBlankLines:
+ Enabled: false
+
+# Offense count: 286
+# Cop supports --auto-correct.
+# Configuration parameters: AllowInHeredoc.
+Layout/TrailingWhitespace:
+ Enabled: false
+
+# Offense count: 1
+Lint/AmbiguousBlockAssociation:
+ Exclude:
+ - 'app/views/cve/info.json.jbuilder'
+
+# Offense count: 1
+Lint/DuplicateMethods:
+ Exclude:
+ - 'lib/bugzilla/bug.rb'
+
+# Offense count: 2
+# Configuration parameters: AllowComments.
+Lint/HandleExceptions:
+ Exclude:
+ - 'Rakefile'
+ - 'app/controllers/bugs_controller.rb'
+
+# Offense count: 1
+Lint/IneffectiveAccessModifier:
+ Exclude:
+ - 'lib/authentication.rb'
+
+# Offense count: 2
+Lint/NestedMethodDefinition:
+ Exclude:
+ - 'app/models/cve.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 3
+Lint/NonLocalExitFromIterator:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+
+# Offense count: 38
+Lint/RescueException:
+ Exclude:
+ - 'app/controllers/bugs_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/tools_controller.rb'
+ - 'app/models/bug.rb'
+ - 'app/models/glsa.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/bugzilla/history.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/tasks/rcov.rake'
+ - 'script/config_init'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Lint/ScriptPermission:
+ Exclude:
+ - 'Rakefile'
+
+# Offense count: 7
+# Cop supports --auto-correct.
+Lint/StringConversionInInterpolation:
+ Exclude:
+ - 'lib/bugzilla/history.rb'
+ - 'test/functional/glsa_controller_test.rb'
+
+# Offense count: 2
+# Configuration parameters: AllowKeywordBlockArguments.
+Lint/UnderscorePrefixedVariableName:
+ Exclude:
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 2
+Lint/UnreachableCode:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+# Configuration parameters: IgnoreEmptyBlocks, AllowUnusedKeywordArguments.
+Lint/UnusedBlockArgument:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/glsa.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 4
+# Cop supports --auto-correct.
+# Configuration parameters: AllowUnusedKeywordArguments, IgnoreEmptyMethods.
+Lint/UnusedMethodArgument:
+ Exclude:
+ - 'app/models/glsa.rb'
+ - 'lib/glsamaker/portage.rb'
+ - 'lib/kramdown_ext.rb'
+
+# Offense count: 16
+Lint/UselessAssignment:
+ Exclude:
+ - 'app/controllers/bug_controller.rb'
+ - 'app/controllers/bugs_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/search_controller.rb'
+ - 'app/models/cve.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/bugzilla/history.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/tasks/cve.rake'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 6
+Metrics/AbcSize:
+ Max: 172
+
+# Offense count: 14
+# Configuration parameters: CountComments, ExcludedMethods.
+# ExcludedMethods: refine
+Metrics/BlockLength:
+ Max: 192
+
+# Offense count: 3
+# Configuration parameters: CountBlocks.
+Metrics/BlockNesting:
+ Max: 4
+
+# Offense count: 5
+# Configuration parameters: CountComments.
+Metrics/ClassLength:
+ Max: 441
+
+# Offense count: 18
+Metrics/CyclomaticComplexity:
+ Max: 24
+
+# Offense count: 24
+# Cop supports --auto-correct.
+# Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
+# URISchemes: http, https
+Metrics/LineLength:
+ Max: 312
+
+# Offense count: 26
+# Configuration parameters: CountComments, ExcludedMethods.
+Metrics/MethodLength:
+ Max: 105
+
+# Offense count: 1
+# Configuration parameters: CountKeywordArgs.
+Metrics/ParameterLists:
+ Max: 6
+
+# Offense count: 14
+Metrics/PerceivedComplexity:
+ Max: 19
+
+# Offense count: 1
+Naming/AccessorMethodName:
+ Exclude:
+ - 'app/models/revision.rb'
+
+# Offense count: 1
+# Configuration parameters: ExpectMatchingDefinition, Regex, IgnoreExecutableScripts, AllowedAcronyms.
+# AllowedAcronyms: CLI, DSL, ACL, API, ASCII, CPU, CSS, DNS, EOF, GUID, HTML, HTTP, HTTPS, ID, IP, JSON, LHS, QPS, RAM, RHS, RPC, SLA, SMTP, SQL, SSH, TCP, TLS, TTL, UDP, UI, UID, UUID, URI, URL, UTF8, VM, XML, XMPP, XSRF, XSS
+Naming/FileName:
+ Exclude:
+ - 'config/initializers/glsamaker-global.rb'
+
+# Offense count: 1
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: snake_case, camelCase
+Naming/MethodName:
+ Exclude:
+ - 'lib/bugzilla/bug.rb'
+
+# Offense count: 7
+# Configuration parameters: NamePrefix, NamePrefixBlacklist, NameWhitelist, MethodDefinitionMacros.
+# NamePrefix: is_, has_, have_
+# NamePrefixBlacklist: is_, has_, have_
+# NameWhitelist: is_a?
+# MethodDefinitionMacros: define_method, define_singleton_method
+Naming/PredicateName:
+ Exclude:
+ - 'spec/**/*'
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/user.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 8
+# Configuration parameters: MinNameLength, AllowNamesEndingInNumbers, AllowedNames, ForbiddenNames.
+# AllowedNames: io, id, to, by, on, in, at, ip, db
+Naming/UncommunicativeMethodParamName:
+ Exclude:
+ - 'app/helpers/application_helper.rb'
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/cve.rb'
+ - 'lib/glsamaker/portage.rb'
+ - 'lib/kramdown_ext.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 18
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: snake_case, camelCase
+Naming/VariableName:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/index_controller.rb'
+
+# Offense count: 1
+Performance/Caller:
+ Exclude:
+ - 'app/controllers/application_controller.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Performance/CompareWithBlock:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Performance/RedundantBlockCall:
+ Exclude:
+ - 'app/helpers/application_helper.rb'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+Performance/RegexpMatch:
+ Exclude:
+ - 'lib/glsamaker/spelling.rb'
+ - 'lib/tasks/cve.rake'
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Performance/StringReplacement:
+ Exclude:
+ - 'lib/glsamaker/xml.rb'
+
+# Offense count: 1
+Performance/UnfreezeString:
+ Exclude:
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 6
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, Include.
+# SupportedStyles: action, filter
+# Include: app/controllers/**/*.rb
+Rails/ActionFilter:
+ Exclude:
+ - 'app/controllers/admin/index_controller.rb'
+ - 'app/controllers/admin/templates_controller.rb'
+ - 'app/controllers/admin/users_controller.rb'
+ - 'app/controllers/application_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/index_controller.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+Rails/ActiveRecordAliases:
+ Exclude:
+ - 'app/controllers/admin/templates_controller.rb'
+ - 'app/controllers/admin/users_controller.rb'
+ - 'app/models/bug.rb'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+# Configuration parameters: Include.
+# Include: **/test/**/*
+Rails/AssertNot:
+ Exclude:
+ - 'test/unit/glsa_test.rb'
+ - 'test/unit/user_test.rb'
+
+# Offense count: 3
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: strict, flexible
+Rails/Date:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+# Configuration parameters: Whitelist.
+# Whitelist: find_by_sql
+Rails/DynamicFindBy:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'lib/authentication.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 4
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: slashes, arguments
+Rails/FilePath:
+ Exclude:
+ - 'lib/bugzilla.rb'
+ - 'lib/glsamaker/spelling.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: Include.
+# Include: app/models/**/*.rb
+Rails/FindEach:
+ Exclude:
+ - 'app/models/revision.rb'
+
+# Offense count: 2
+# Configuration parameters: Include.
+# Include: app/models/**/*.rb
+Rails/HasAndBelongsToMany:
+ Exclude:
+ - 'app/models/cpe.rb'
+ - 'app/models/cve.rb'
+
+# Offense count: 9
+# Configuration parameters: Include.
+# Include: app/models/**/*.rb
+Rails/HasManyOrHasOneDependent:
+ Exclude:
+ - 'app/models/cve.rb'
+ - 'app/models/user.rb'
+
+# Offense count: 1
+# Configuration parameters: Include.
+# Include: app/helpers/**/*.rb
+Rails/HelperInstanceVariable:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+
+# Offense count: 21
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: numeric, symbolic
+Rails/HttpStatus:
+ Exclude:
+ - 'app/controllers/bugs_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/tools_controller.rb'
+
+# Offense count: 15
+# Configuration parameters: Include.
+# Include: app/models/**/*.rb
+Rails/InverseOf:
+ Exclude:
+ - 'app/models/comment.rb'
+ - 'app/models/cve.rb'
+ - 'app/models/cve_change.rb'
+ - 'app/models/cve_comment.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/revision.rb'
+ - 'app/models/user.rb'
+
+# Offense count: 4
+Rails/OutputSafety:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/application_helper.rb'
+ - 'lib/glsamaker/spelling.rb'
+
+# Offense count: 1
+# Configuration parameters: Blacklist, Whitelist.
+# Blacklist: decrement!, decrement_counter, increment!, increment_counter, toggle!, touch, update_all, update_attribute, update_column, update_columns, update_counters
+Rails/SkipsModelValidations:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+
+# Offense count: 11
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: strict, flexible
+Rails/TimeZone:
+ Exclude:
+ - 'app/models/glsa.rb'
+ - 'lib/authorization.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/bugzilla/comment.rb'
+ - 'lib/bugzilla/history.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+# Configuration parameters: Include.
+# Include: app/models/**/*.rb
+Rails/Validation:
+ Exclude:
+ - 'app/models/glsa.rb'
+ - 'app/models/revision.rb'
+ - 'app/models/user.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Security/YAMLLoad:
+ Exclude:
+ - 'script/config_init'
+
+# Offense count: 1
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: inline, group
+Style/AccessModifierDeclarations:
+ Exclude:
+ - 'lib/glsamaker/http.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: prefer_alias, prefer_alias_method
+Style/Alias:
+ Exclude:
+ - 'lib/bugzilla/bug.rb'
+
+# Offense count: 28
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: always, conditionals
+Style/AndOr:
+ Exclude:
+ - 'app/controllers/application_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/application_helper.rb'
+ - 'app/models/cve.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/user.rb'
+ - 'lib/authentication.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/glsamaker/diff.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/BlockComments:
+ Exclude:
+ - 'app/models/revision.rb'
+
+# Offense count: 13
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, ProceduralMethods, FunctionalMethods, IgnoredMethods, AllowBracesOnProceduralOneLiners.
+# SupportedStyles: line_count_based, semantic, braces_for_chaining, always_braces
+# ProceduralMethods: benchmark, bm, bmbm, create, each_with_object, measure, new, realtime, tap, with_object
+# FunctionalMethods: let, let!, subject, watch
+# IgnoredMethods: lambda, proc, it
+Style/BlockDelimiters:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'config/deploy.rb'
+ - 'lib/glsamaker/http.rb'
+ - 'test/unit/cve_test.rb'
+
+# Offense count: 13
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: braces, no_braces, context_dependent
+Style/BracesAroundHashParameters:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'config/deploy.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/glsamaker/http.rb'
+ - 'test/integration/authentication_test.rb'
+
+# Offense count: 11
+# Cop supports --auto-correct.
+# Configuration parameters: AutoCorrect, EnforcedStyle.
+# SupportedStyles: nested, compact
+Style/ClassAndModuleChildren:
+ Exclude:
+ - 'app/controllers/admin/index_controller.rb'
+ - 'app/controllers/admin/templates_controller.rb'
+ - 'app/controllers/admin/users_controller.rb'
+ - 'app/helpers/admin/index_helper.rb'
+ - 'app/helpers/admin/templates_helper.rb'
+ - 'app/helpers/admin/users_helper.rb'
+ - 'lib/bugzilla/history.rb'
+ - 'test/functional/admin/index_controller_test.rb'
+ - 'test/functional/admin/templates_controller_test.rb'
+ - 'test/functional/admin/users_controller_test.rb'
+ - 'test/test_helper.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/ColonMethodCall:
+ Exclude:
+ - 'app/models/cve.rb'
+
+# Offense count: 13
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, SingleLineConditionsOnly, IncludeTernaryExpressions.
+# SupportedStyles: assign_to_condition, assign_inside_condition
+Style/ConditionalAssignment:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/application_helper.rb'
+ - 'app/models/cve.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/glsamaker/portage.rb'
+ - 'lib/glsamaker/spelling.rb'
+ - 'lib/tasks/import.rake'
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/DefWithParentheses:
+ Exclude:
+ - 'lib/bugzilla/bug.rb'
+
+# Offense count: 4
+# Cop supports --auto-correct.
+Style/EmptyLiteral:
+ Exclude:
+ - 'lib/tasks/import.rake'
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 6
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: compact, expanded
+Style/EmptyMethod:
+ Exclude:
+ - 'app/controllers/admin/index_controller.rb'
+ - 'app/controllers/bugs_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'app/controllers/search_controller.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/Encoding:
+ Exclude:
+ - 'db/schema.rb'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+Style/ExpandPathArguments:
+ Exclude:
+ - 'Rakefile'
+ - 'bin/bundle'
+ - 'bin/rails'
+ - 'bin/setup'
+ - 'config/application.rb'
+ - 'config/boot.rb'
+ - 'config/environment.rb'
+ - 'script/rails'
+ - 'test/test_helper.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: each, for
+Style/For:
+ Exclude:
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 13
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: annotated, template, unannotated
+Style/FormatStringToken:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/helpers/application_helper.rb'
+ - 'app/models/cve.rb'
+
+# Offense count: 159
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: always, never
+Style/FrozenStringLiteralComment:
+ Enabled: false
+
+# Offense count: 17
+# Configuration parameters: MinBodyLength.
+Style/GuardClause:
+ Exclude:
+ - 'app/controllers/admin/users_controller.rb'
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/models/comment.rb'
+ - 'app/models/glsa.rb'
+ - 'lib/authentication.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/glsamaker/mail.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 550
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, UseHashRocketsWithSymbolValues, PreferHashRocketsForNonAlnumEndingSymbols.
+# SupportedStyles: ruby19, hash_rockets, no_mixed_keys, ruby19_no_mixed_keys
+Style/HashSyntax:
+ Enabled: false
+
+# Offense count: 5
+# Configuration parameters: AllowIfModifier.
+Style/IfInsideElse:
+ Exclude:
+ - 'app/helpers/application_helper.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 40
+# Cop supports --auto-correct.
+Style/IfUnlessModifier:
+ Enabled: false
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: InverseMethods, InverseBlocks.
+Style/InverseMethods:
+ Exclude:
+ - 'app/views/glsa/_glsa.xml.builder'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/LineEndConcatenation:
+ Exclude:
+ - 'db/migrate/20100918223549_add_system_user.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+# Configuration parameters: IgnoredMethods.
+Style/MethodCallWithoutArgsParentheses:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Style/MultilineIfThen:
+ Exclude:
+ - 'lib/authentication.rb'
+ - 'script/db-backup'
+
+# Offense count: 18
+# Cop supports --auto-correct.
+Style/MultilineWhenThen:
+ Exclude:
+ - 'lib/bugzilla/bug.rb'
+
+# Offense count: 14
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: literals, strict
+Style/MutableConstant:
+ Exclude:
+ - 'config/environment.rb'
+ - 'config/initializers/glsamaker-global.rb'
+ - 'config/initializers/glsamaker.rb'
+ - 'lib/kramdown_ext.rb'
+ - 'lib/tasks/cve.rake'
+ - 'lib/tasks/import.rake'
+ - 'script/db-backup'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: both, prefix, postfix
+Style/NegatedIf:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 4
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, MinBodyLength.
+# SupportedStyles: skip_modifier_ifs, always
+Style/Next:
+ Exclude:
+ - 'app/controllers/tools_controller.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 18
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: predicate, comparison
+Style/NilComparison:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/index_controller.rb'
+ - 'app/controllers/tools_controller.rb'
+ - 'app/models/user.rb'
+ - 'lib/authentication.rb'
+ - 'lib/bugzilla/history.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+# Configuration parameters: IncludeSemanticChanges.
+Style/NonNilCheck:
+ Exclude:
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+Style/Not:
+ Exclude:
+ - 'app/controllers/search_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/user.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedOctalStyle.
+# SupportedOctalStyles: zero_with_o, zero_only
+Style/NumericLiteralPrefix:
+ Exclude:
+ - 'lib/bugzilla.rb'
+ - 'script/config_init'
+
+# Offense count: 24
+# Cop supports --auto-correct.
+# Configuration parameters: Strict.
+Style/NumericLiterals:
+ MinDigits: 15
+
+# Offense count: 28
+# Cop supports --auto-correct.
+# Configuration parameters: AutoCorrect, EnforcedStyle, IgnoredMethods.
+# SupportedStyles: predicate, comparison
+Style/NumericPredicate:
+ Exclude:
+ - 'spec/**/*'
+ - 'app/controllers/admin/users_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/tools_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/user.rb'
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'lib/authorization.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/glsamaker/bugs.rb'
+ - 'lib/glsamaker/diff.rb'
+ - 'lib/tasks/cve.rake'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 5
+# Cop supports --auto-correct.
+# Configuration parameters: PreferredDelimiters.
+Style/PercentLiteralDelimiters:
+ Exclude:
+ - 'app/models/package.rb'
+ - 'config/application.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 38
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: short, verbose
+Style/PreferredHashMethods:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/helpers/application_helper.rb'
+ - 'lib/bugzilla.rb'
+ - 'lib/bugzilla/history.rb'
+ - 'lib/glsamaker/xml.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/Proc:
+ Exclude:
+ - 'app/models/comment.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Style/RedundantBegin:
+ Exclude:
+ - 'app/controllers/bugs_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/RedundantException:
+ Exclude:
+ - 'lib/authentication.rb'
+
+# Offense count: 8
+# Cop supports --auto-correct.
+# Configuration parameters: AllowMultipleReturnValues.
+Style/RedundantReturn:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/revision.rb'
+ - 'lib/authentication.rb'
+ - 'lib/glsamaker/bugs.rb'
+
+# Offense count: 38
+# Cop supports --auto-correct.
+Style/RedundantSelf:
+ Exclude:
+ - 'app/models/bug.rb'
+ - 'app/models/cpe.rb'
+ - 'app/models/cve.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/package.rb'
+ - 'app/models/revision.rb'
+ - 'app/models/user.rb'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/glsamaker/bugs.rb'
+
+# Offense count: 10
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, AllowInnerSlashes.
+# SupportedStyles: slashes, percent_r, mixed
+Style/RegexpLiteral:
+ Exclude:
+ - 'app/controllers/tools_controller.rb'
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/package.rb'
+ - 'lib/glsamaker/portage.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: implicit, explicit
+Style/RescueStandardError:
+ Exclude:
+ - 'app/helpers/application_helper.rb'
+ - 'lib/tasks/import.rake'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/SelfAssignment:
+ Exclude:
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: only_raise, only_fail, semantic
+Style/SignalException:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'lib/tasks/cve.rake'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: .
+# SupportedStyles: use_perl_names, use_english_names
+Style/SpecialGlobalVars:
+ EnforcedStyle: use_perl_names
+
+# Offense count: 4
+# Cop supports --auto-correct.
+Style/StderrPuts:
+ Exclude:
+ - 'lib/tasks/cve.rake'
+ - 'lib/tasks/rcov.rake'
+ - 'script/config_init'
+
+# Offense count: 809
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
+# SupportedStyles: single_quotes, double_quotes
+Style/StringLiterals:
+ Enabled: false
+
+# Offense count: 10
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle.
+# SupportedStyles: single_quotes, double_quotes
+Style/StringLiteralsInInterpolation:
+ Exclude:
+ - 'app/helpers/glsa_helper.rb'
+ - 'app/models/cve.rb'
+ - 'app/models/glsa.rb'
+
+# Offense count: 11
+# Cop supports --auto-correct.
+# Configuration parameters: MinSize.
+# SupportedStyles: percent, brackets
+Style/SymbolArray:
+ EnforcedStyle: brackets
+
+# Offense count: 17
+# Cop supports --auto-correct.
+# Configuration parameters: IgnoredMethods.
+# IgnoredMethods: respond_to, define_method
+Style/SymbolProc:
+ Exclude:
+ - 'app/controllers/cve_controller.rb'
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/models/cve.rb'
+ - 'app/models/glsa.rb'
+ - 'app/models/revision.rb'
+ - 'app/views/cve/info.json.jbuilder'
+ - 'lib/glsamaker/diff.rb'
+ - 'lib/tasks/rcov.rake'
+ - 'test/unit/glsa_test.rb'
+ - 'test/unit/revision_test.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyle, AllowSafeAssignment.
+# SupportedStyles: require_parentheses, require_no_parentheses, require_parentheses_when_complex
+Style/TernaryParentheses:
+ Exclude:
+ - 'app/views/glsa/_glsa.xml.builder'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: EnforcedStyleForMultiline.
+# SupportedStylesForMultiline: comma, consistent_comma, no_comma
+Style/TrailingCommaInHashLiteral:
+ Exclude:
+ - 'lib/bugzilla.rb'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+# Configuration parameters: ExactNameMatch, AllowPredicates, AllowDSLWriters, IgnoreClassMethods, Whitelist.
+# Whitelist: to_ary, to_a, to_c, to_enum, to_h, to_hash, to_i, to_int, to_io, to_open, to_path, to_proc, to_r, to_regexp, to_str, to_s, to_sym
+Style/TrivialAccessors:
+ Exclude:
+ - 'lib/glsamaker/bugs.rb'
+
+# Offense count: 3
+# Cop supports --auto-correct.
+Style/UnlessElse:
+ Exclude:
+ - 'app/controllers/bugs_controller.rb'
+ - 'app/controllers/comments_controller.rb'
+ - 'lib/bugzilla/history.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+Style/UnneededInterpolation:
+ Exclude:
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'lib/tasks/rcov.rake'
+
+# Offense count: 1
+# Cop supports --auto-correct.
+Style/UnpackFirst:
+ Exclude:
+ - 'lib/authentication.rb'
+
+# Offense count: 2
+# Cop supports --auto-correct.
+# Configuration parameters: WordRegex.
+# SupportedStyles: percent, brackets
+Style/WordArray:
+ EnforcedStyle: percent
+ MinSize: 6
+
+# Offense count: 11
+# Cop supports --auto-correct.
+Style/ZeroLengthPredicate:
+ Exclude:
+ - 'app/controllers/glsa_controller.rb'
+ - 'app/controllers/tools_controller.rb'
+ - 'app/models/glsa.rb'
+ - 'app/views/glsa/_glsa.xml.builder'
+ - 'lib/bugzilla/bug.rb'
+ - 'lib/tasks/cve.rake'
+ - 'lib/tasks/import.rake'
diff --git a/Gemfile b/Gemfile
index 7b01430..4ce9184 100644
--- a/Gemfile
+++ b/Gemfile
@@ -59,4 +59,8 @@ group :test do
gem 'ci_reporter'
gem 'rspec'
gem 'minitest-reporters'
+
+ gem 'rubocop'
+ gem 'rubocop-performance'
+ gem 'rubocop-rails'
end
diff --git a/Gemfile.lock b/Gemfile.lock
index 6ace946..ecdef7d 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -43,10 +43,11 @@ GEM
minitest (~> 5.1)
thread_safe (~> 0.3, >= 0.3.4)
tzinfo (~> 1.1)
- airbrussh (1.3.1)
+ airbrussh (1.3.2)
sshkit (>= 1.6.1, != 1.7.0)
ansi (1.5.0)
arel (6.0.4)
+ ast (2.4.0)
builder (3.2.3)
capistrano (3.11.0)
airbrussh (>= 1.0.0)
@@ -60,8 +61,8 @@ GEM
crass (1.0.4)
daemons (1.3.1)
diff-lcs (1.3)
- docile (1.3.1)
- domain_name (0.5.20180417)
+ docile (1.3.2)
+ domain_name (0.5.20190701)
unf (>= 0.0.5, < 1.0.0)
erubis (2.7.0)
eventmachine (1.2.7)
@@ -73,13 +74,13 @@ GEM
i18n (0.9.5)
concurrent-ruby (~> 1.0)
innertube (1.1.0)
- jbuilder (2.8.0)
+ jaro_winkler (1.5.3)
+ jbuilder (2.9.1)
activesupport (>= 4.2.0)
- multi_json (>= 1.2)
joiner (0.3.4)
activerecord (>= 4.1.0)
json (1.8.6)
- kramdown (2.0.0)
+ kramdown (2.1.0)
loofah (2.2.3)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
@@ -97,7 +98,7 @@ GEM
middleware (0.1.0)
mime-types (3.2.2)
mime-types-data (~> 3.2015)
- mime-types-data (3.2018.0812)
+ mime-types-data (3.2019.0331)
mini_mime (1.0.2)
mini_portile2 (2.4.0)
minitest (5.11.3)
@@ -106,17 +107,19 @@ GEM
builder
minitest (>= 5.0)
ruby-progressbar
- multi_json (1.13.1)
mysql2 (0.3.21)
net-http-digest_auth (1.4.1)
- net-http-persistent (3.0.0)
+ net-http-persistent (3.0.1)
connection_pool (~> 2.2)
- net-scp (1.2.1)
- net-ssh (>= 2.6.5)
- net-ssh (5.1.0)
+ net-scp (2.0.0)
+ net-ssh (>= 2.6.5, < 6.0.0)
+ net-ssh (5.2.0)
nokogiri (1.10.3)
mini_portile2 (~> 2.4.0)
ntlm-http (0.1.1)
+ parallel (1.17.0)
+ parser (2.6.3.0)
+ ast (~> 2.4.0)
rack (1.6.11)
rack-test (0.6.3)
rack (>= 1.0)
@@ -144,23 +147,36 @@ GEM
activesupport (= 4.2.11.1)
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
+ rainbow (3.0.0)
rake (10.4.2)
riddle (2.3.2)
rspec (3.8.0)
rspec-core (~> 3.8.0)
rspec-expectations (~> 3.8.0)
rspec-mocks (~> 3.8.0)
- rspec-core (3.8.0)
+ rspec-core (3.8.2)
rspec-support (~> 3.8.0)
- rspec-expectations (3.8.2)
+ rspec-expectations (3.8.4)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.8.0)
- rspec-mocks (3.8.0)
+ rspec-mocks (3.8.1)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.8.0)
- rspec-support (3.8.0)
- ruby-progressbar (1.10.0)
- simplecov (0.16.1)
+ rspec-support (3.8.2)
+ rubocop (0.73.0)
+ jaro_winkler (~> 1.5.1)
+ parallel (~> 1.10)
+ parser (>= 2.6)
+ rainbow (>= 2.2.2, < 4.0)
+ ruby-progressbar (~> 1.7)
+ unicode-display_width (>= 1.4.0, < 1.7)
+ rubocop-performance (1.4.0)
+ rubocop (>= 0.71.0)
+ rubocop-rails (2.2.1)
+ rack (>= 1.1)
+ rubocop (>= 0.72.0)
+ ruby-progressbar (1.10.1)
+ simplecov (0.17.0)
docile (~> 1.1)
json (>= 1.8, < 3)
simplecov-html (~> 0.10.0)
@@ -172,7 +188,7 @@ GEM
actionpack (>= 4.0)
activesupport (>= 4.0)
sprockets (>= 3.0.0)
- sshkit (1.18.1)
+ sshkit (1.19.1)
net-scp (>= 1.1.2)
net-ssh (>= 2.8.0)
text-format-revised (1.1.0)
@@ -195,7 +211,8 @@ GEM
thread_safe (~> 0.1)
unf (0.1.4)
unf_ext
- unf_ext (0.0.7.5)
+ unf_ext (0.0.7.6)
+ unicode-display_width (1.6.0)
webrobots (0.1.2)
xmlrpc (0.3.0)
@@ -218,6 +235,9 @@ DEPENDENCIES
rails (~> 4.2)
rake (= 10.4.2)
rspec
+ rubocop
+ rubocop-performance
+ rubocop-rails
simplecov
text-format-revised
thin