diff options
author | David RodrÃguez <deivid.rodriguez@riseup.net> | 2019-03-04 01:00:16 +0100 |
---|---|---|
committer | David RodrÃguez <deivid.rodriguez@riseup.net> | 2019-03-04 01:12:34 +0100 |
commit | cc0ecea9dd64fa06d318e79d20ab985945b11648 (patch) | |
tree | 582f03681a0b4273e36c831e86fbf61b887834f6 | |
parent | 719a9c31e2ca4e454f4494a4544beb6c5db4555f (diff) | |
download | bundler-cc0ecea9dd64fa06d318e79d20ab985945b11648.tar.gz |
Auto-correct `Style/TrailingCommaInArrayLiteral` offenses
-rw-r--r-- | .rubocop_todo.yml | 10 | ||||
-rw-r--r-- | lib/bundler/gem_helpers.rb | 2 | ||||
-rw-r--r-- | lib/bundler/ruby_version.rb | 2 | ||||
-rw-r--r-- | lib/bundler/similarity_detector.rb | 2 |
4 files changed, 3 insertions, 13 deletions
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index 52b93d223f..dcddcb2774 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -595,16 +595,6 @@ Style/StderrPuts: Style/SymbolArray: EnforcedStyle: brackets -# Offense count: 3 -# Cop supports --auto-correct. -# Configuration parameters: EnforcedStyleForMultiline. -# SupportedStylesForMultiline: comma, consistent_comma, no_comma -Style/TrailingCommaInArrayLiteral: - Exclude: - - 'lib/bundler/gem_helpers.rb' - - 'lib/bundler/ruby_version.rb' - - 'lib/bundler/similarity_detector.rb' - # Offense count: 6 # Cop supports --auto-correct. # Configuration parameters: EnforcedStyleForMultiline. diff --git a/lib/bundler/gem_helpers.rb b/lib/bundler/gem_helpers.rb index 019ae10c66..9d35169b99 100644 --- a/lib/bundler/gem_helpers.rb +++ b/lib/bundler/gem_helpers.rb @@ -10,7 +10,7 @@ module Bundler [Gem::Platform.new("universal-mingw32"), Gem::Platform.new("universal-mingw32")], [Gem::Platform.new("x64-mingw32"), Gem::Platform.new("x64-mingw32")], [Gem::Platform.new("x86_64-mingw32"), Gem::Platform.new("x64-mingw32")], - [Gem::Platform.new("mingw32"), Gem::Platform.new("x86-mingw32")] + [Gem::Platform.new("mingw32"), Gem::Platform.new("x86-mingw32")], ].freeze def generic(p) diff --git a/lib/bundler/ruby_version.rb b/lib/bundler/ruby_version.rb index e6c31a94c9..ebfdb1a086 100644 --- a/lib/bundler/ruby_version.rb +++ b/lib/bundler/ruby_version.rb @@ -74,7 +74,7 @@ module Bundler @host ||= [ RbConfig::CONFIG["host_cpu"], RbConfig::CONFIG["host_vendor"], - RbConfig::CONFIG["host_os"] + RbConfig::CONFIG["host_os"], ].join("-") end diff --git a/lib/bundler/similarity_detector.rb b/lib/bundler/similarity_detector.rb index b7f3ee7afa..f698f46a4c 100644 --- a/lib/bundler/similarity_detector.rb +++ b/lib/bundler/similarity_detector.rb @@ -51,7 +51,7 @@ module Bundler dm[i][j] = [ dm[i - 1][j - 1] + (this[j - 1] == that[i - 1] ? 0 : sub), dm[i][j - 1] + ins, - dm[i - 1][j] + del + dm[i - 1][j] + del, ].min end end |