diff options
author | Erick Sasse <esasse@gmail.com> | 2015-07-17 20:12:13 -0300 |
---|---|---|
committer | Erick Sasse <esasse@gmail.com> | 2015-07-17 20:12:13 -0300 |
commit | d6ba29d35b37f2a658e8ecd51a38fbead3205365 (patch) | |
tree | e2bb0529eff6763b509dee4217321bb192f09212 | |
parent | 7515ea86066b0f81f93a212b22a2219605aa7e75 (diff) | |
download | bundler-d6ba29d35b37f2a658e8ecd51a38fbead3205365.tar.gz |
Fix Style/SpaceInsideBrackets
-rw-r--r-- | .rubocop_todo.yml | 5 | ||||
-rw-r--r-- | lib/bundler/cli/platform.rb | 4 | ||||
-rw-r--r-- | lib/bundler/definition.rb | 2 | ||||
-rw-r--r-- | lib/bundler/ruby_version.rb | 8 | ||||
-rw-r--r-- | spec/commands/outdated_spec.rb | 2 | ||||
-rw-r--r-- | spec/support/fakeweb/windows.rb | 4 |
6 files changed, 10 insertions, 15 deletions
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index f36f1340ef..9cf2db1ce7 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -465,11 +465,6 @@ Style/SpaceBeforeSemicolon: Style/SpaceInsideBlockBraces: Enabled: false -# Offense count: 15 -# Cop supports --auto-correct. -Style/SpaceInsideBrackets: - Enabled: false - # Offense count: 72 # Cop supports --auto-correct. # Configuration parameters: EnforcedStyle, EnforcedStyleForEmptyBraces, SupportedStyles. diff --git a/lib/bundler/cli/platform.rb b/lib/bundler/cli/platform.rb index 8a3855370b..2c09faad3f 100644 --- a/lib/bundler/cli/platform.rb +++ b/lib/bundler/cli/platform.rb @@ -7,8 +7,8 @@ module Bundler def run platforms, ruby_version = Bundler.ui.silence do - [ Bundler.definition.platforms.map {|p| "* #{p}" }, - Bundler.definition.ruby_version ] + [Bundler.definition.platforms.map {|p| "* #{p}" }, + Bundler.definition.ruby_version] end output = [] diff --git a/lib/bundler/definition.rb b/lib/bundler/definition.rb index d5b7bad79c..45a4df1dfb 100644 --- a/lib/bundler/definition.rb +++ b/lib/bundler/definition.rb @@ -459,7 +459,7 @@ module Bundler source = spec && spec.source if source && source.respond_to?(:local_override!) source.unlock! if @unlock[:gems].include?(spec.name) - locals << [ source, source.local_override!(v) ] + locals << [source, source.local_override!(v)] end end diff --git a/lib/bundler/ruby_version.rb b/lib/bundler/ruby_version.rb index da6ebae080..f10a9d2703 100644 --- a/lib/bundler/ruby_version.rb +++ b/lib/bundler/ruby_version.rb @@ -46,13 +46,13 @@ module Bundler # 3. engine_version def diff(other) if engine != other.engine && @input_engine - [ :engine, engine, other.engine ] + [:engine, engine, other.engine] elsif version != other.version - [ :version, version, other.version ] + [:version, version, other.version] elsif engine_version != other.engine_version && @input_engine - [ :engine_version, engine_version, other.engine_version ] + [:engine_version, engine_version, other.engine_version] elsif patchlevel != other.patchlevel && @patchlevel - [ :patchlevel, patchlevel, other.patchlevel ] + [:patchlevel, patchlevel, other.patchlevel] else nil end diff --git a/spec/commands/outdated_spec.rb b/spec/commands/outdated_spec.rb index 0b47cba1a7..a0d5f3036c 100644 --- a/spec/commands/outdated_spec.rb +++ b/spec/commands/outdated_spec.rb @@ -32,7 +32,7 @@ describe "bundle outdated" do expect(out).to include("foo (newest 1.0") # Gem names are one per-line, between "*" and their parenthesized version. - gem_list = out.split("\n").map { |g| g[ /\* (.*) \(/, 1] }.compact + gem_list = out.split("\n").map { |g| g[/\* (.*) \(/, 1] }.compact expect(gem_list).to eq(gem_list.sort) end diff --git a/spec/support/fakeweb/windows.rb b/spec/support/fakeweb/windows.rb index 02be5d6cc3..f8fe5f6e70 100644 --- a/spec/support/fakeweb/windows.rb +++ b/spec/support/fakeweb/windows.rb @@ -1,10 +1,10 @@ require File.expand_path("../../path.rb", __FILE__) include Spec::Path -files = [ "specs.4.8.gz", +files = ["specs.4.8.gz", "prerelease_specs.4.8.gz", "quick/Marshal.4.8/rcov-1.0-mswin32.gemspec.rz", - "gems/rcov-1.0-mswin32.gem" ] + "gems/rcov-1.0-mswin32.gem"] # Set up pretend http gem server with FakeWeb $LOAD_PATH.unshift "#{Dir[base_system_gems.join("gems/fakeweb*/lib")].first}" |