diff options
author | Samuel Giddins <segiddins@segiddins.me> | 2016-03-09 11:14:53 -0600 |
---|---|---|
committer | Samuel Giddins <segiddins@segiddins.me> | 2016-03-09 11:14:53 -0600 |
commit | 2d0fc718ea1a7365182152af370a0a5d418df220 (patch) | |
tree | 41978063c783b3c34c1e19d32d923a3218af5d48 | |
parent | 2d7d9c8b4404a74fbb4baacc1cee809318f3123e (diff) | |
download | bundler-2d0fc718ea1a7365182152af370a0a5d418df220.tar.gz |
[RuboCop] Update to 0.38.0seg-rubocop-0.38
-rw-r--r-- | .rubocop_todo.yml | 20 | ||||
-rw-r--r-- | Rakefile | 4 | ||||
-rwxr-xr-x | bin/rubocop | 2 | ||||
-rw-r--r-- | lib/bundler/cli/outdated.rb | 6 | ||||
-rw-r--r-- | lib/bundler/mirror.rb | 6 |
5 files changed, 17 insertions, 21 deletions
diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index cec50c1b88..539f92a538 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -1,6 +1,6 @@ # This configuration was generated by # `rubocop --auto-gen-config` -# on 2016-02-09 10:53:24 -0600 using RuboCop version 0.37.1. +# on 2016-03-09 11:11:00 -0600 using RuboCop version 0.38.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 @@ -52,7 +52,7 @@ Lint/UselessAssignment: - 'lib/bundler/index.rb' - 'lib/bundler/installer.rb' -# Offense count: 1295 +# Offense count: 1327 # Configuration parameters: AllowHeredoc, AllowURI, URISchemes. # URISchemes: http, https Metrics/LineLength: @@ -63,9 +63,9 @@ Metrics/LineLength: Metrics/ParameterLists: Max: 6 -# Offense count: 52 +# Offense count: 55 Metrics/PerceivedComplexity: - Max: 54 + Max: 51 # Offense count: 6 # Cop supports --auto-correct. @@ -110,26 +110,23 @@ Style/CaseEquality: Style/ClassAndModuleChildren: Enabled: false -# Offense count: 14 +# Offense count: 11 # Cop supports --auto-correct. # Configuration parameters: SingleLineConditionsOnly. Style/ConditionalAssignment: Exclude: - - 'lib/bundler.rb' - 'lib/bundler/cli.rb' - 'lib/bundler/cli/gem.rb' - 'lib/bundler/cli/lock.rb' - - 'lib/bundler/cli/outdated.rb' - 'lib/bundler/cli/platform.rb' - 'lib/bundler/dsl.rb' - 'lib/bundler/lazy_specification.rb' - - 'lib/bundler/mirror.rb' - 'lib/bundler/psyched_yaml.rb' - 'lib/bundler/rubygems_integration.rb' - 'lib/bundler/source/git.rb' - 'lib/bundler/source/rubygems.rb' -# Offense count: 118 +# Offense count: 119 Style/Documentation: Enabled: false @@ -173,11 +170,10 @@ Style/ModuleFunction: Style/MultilineMethodCallIndentation: Enabled: false -# Offense count: 5 +# Offense count: 4 Style/NestedParenthesizedCalls: Exclude: - 'lib/bundler/resolver.rb' - - 'spec/bundler/shared_helpers_spec.rb' - 'spec/commands/lock_spec.rb' - 'spec/runtime/setup_spec.rb' @@ -195,7 +191,7 @@ Style/PredicateName: - 'lib/bundler/source/git/git_proxy.rb' - 'lib/bundler/source/path.rb' -# Offense count: 23 +# Offense count: 25 # Configuration parameters: EnforcedStyle, SupportedStyles. # SupportedStyles: compact, exploded Style/RaiseArgs: @@ -34,7 +34,7 @@ namespace :spec do deps = Hash[BUNDLER_SPEC.development_dependencies.map do |d| [d.name, d.requirement.to_s] end] - deps["rubocop"] ||= "= 0.37.1" if RUBY_VERSION >= "1.9.3" # can't go in the gemspec because of the ruby version requirement + deps["rubocop"] ||= "= 0.38.0" if RUBY_VERSION >= "1.9.3" # can't go in the gemspec because of the ruby version requirement # JRuby can't build ronn or rdiscount, so we skip that if defined?(RUBY_ENGINE) && RUBY_ENGINE == "jruby" @@ -88,7 +88,7 @@ begin if RUBY_VERSION >= "1.9.3" # can't go in the gemspec because of the ruby version requirement - gem "rubocop", "= 0.37.1" + gem "rubocop", "= 0.38.0" require "rubocop/rake_task" RuboCop::RakeTask.new end diff --git a/bin/rubocop b/bin/rubocop index 01840861cc..bc620424a3 100755 --- a/bin/rubocop +++ b/bin/rubocop @@ -10,7 +10,7 @@ bundler_spec.dependencies.each do |dep| gem dep.name, dep.requirement.to_s end -gem "rubocop", "= 0.37.1" +gem "rubocop", "= 0.38.0" Gem.finish_resolve if Gem.respond_to?(:finish_resolve) diff --git a/lib/bundler/cli/outdated.rb b/lib/bundler/cli/outdated.rb index 4296ec630d..111ccadbd3 100644 --- a/lib/bundler/cli/outdated.rb +++ b/lib/bundler/cli/outdated.rb @@ -23,11 +23,11 @@ module Bundler current_dependencies = {} Bundler.ui.silence { Bundler.load.dependencies.each {|dep| current_dependencies[dep.name] = dep } } - if gems.empty? && sources.empty? + definition = if gems.empty? && sources.empty? # We're doing a full update - definition = Bundler.definition(true) + Bundler.definition(true) else - definition = Bundler.definition(:gems => gems, :sources => sources) + Bundler.definition(:gems => gems, :sources => sources) end definition_resolution = proc { options["local"] ? definition.resolve_with_cache! : definition.resolve_remotely! } diff --git a/lib/bundler/mirror.rb b/lib/bundler/mirror.rb index cc427d7314..655d2b3d07 100644 --- a/lib/bundler/mirror.rb +++ b/lib/bundler/mirror.rb @@ -32,10 +32,10 @@ module Bundler def parse(key, value) config = MirrorConfig.new(key, value) - if config.all? - mirror = @all + mirror = if config.all? + @all else - mirror = (@mirrors[config.uri] = @mirrors[config.uri] || Mirror.new) + (@mirrors[config.uri] = @mirrors[config.uri] || Mirror.new) end config.update_mirror(mirror) end |