bundler 1.10.3 → 1.10.4

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of bundler might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d16968eae1c5a56edc60ec57ec834ffdfb9af52e
4
- data.tar.gz: 2d179b57f5b43cd083a0660b85b84a2eccd322b0
3
+ metadata.gz: 96e28345d9c519a160bdabca5ae4746d05a1bc4a
4
+ data.tar.gz: bb30271388491a82103e07acb7d5e00084b6cfd7
5
5
  SHA512:
6
- metadata.gz: 8c648e2a488da6ad4a30adf96d0f07834c20a5a4e971e3182c220fff3ae780236a43a5a0ef382e73680a56725e20fda88a964eb5772e788e578481246395cbf0
7
- data.tar.gz: 5ece721abfc3d426cf737e57d480a32b6ecd4a6fe052eb6f8142078d2612b578c4ba8908a5fab3065d1954086f9544f8a882c45bbd85b2ab33ec9b18e6a78839
6
+ metadata.gz: 6e5829c1f677281766f56a786ca7e2ba4dedc3aebed23d74e447a762599d77a738dbb1fbad49334d84682cc6ce566e215f7dc62d3377b825c60c9c2f7aad283d
7
+ data.tar.gz: 2743f91766b319a5192e0a12aedb5e4ea24d7f412ffdb16feff1a43e3ae7b5db02ec3fe81de4aa7576707d170c36d138362fbd9125ebd5507ab6810ebc62c1ac
@@ -42,7 +42,7 @@ env:
42
42
  # We need to know if changes to rubygems will break bundler on release
43
43
  - RGV=master
44
44
  # Test the latest rubygems release with all of our supported rubies
45
- - RGV=v2.4.7
45
+ - RGV=v2.4.8
46
46
 
47
47
  matrix:
48
48
  fast_finish: true
@@ -100,7 +100,7 @@ matrix:
100
100
  # Ruby 1.9.2 sanity check
101
101
  # (but it's just too slow and sometimes goes over the Travis limit)
102
102
  - rvm: 1.9.2
103
- env: RGV=v2.4.7
103
+ env: RGV=v2.4.8
104
104
  # Ruby-head (we want to know how we're doing, but not fail the build)
105
105
  - rvm: ruby-head
106
106
  env: RGV=master
@@ -1,3 +1,14 @@
1
+ ## 1.10.4 (2015-06-16)
2
+
3
+ Workarounds:
4
+
5
+ - don't add BUNDLED WITH to the lock when Spring runs `check` over and over (@indirect)
6
+
7
+ Bugfixes:
8
+
9
+ - display "with native extensions" log output correctly (@ivantsepp)
10
+ - alias `i` to `install`, `c` to `check`, and `e` to `exec` (@indirect)
11
+
1
12
  ## 1.10.3 (2015-06-03)
2
13
 
3
14
  Bugfixes:
data/Rakefile CHANGED
@@ -171,7 +171,7 @@ begin
171
171
  rubyopt = ENV["RUBYOPT"]
172
172
  # When editing this list, also edit .travis.yml!
173
173
  branches = %w(master)
174
- releases = %w(v1.3.6 v1.3.7 v1.4.2 v1.5.3 v1.6.2 v1.7.2 v1.8.29 v2.0.14 v2.1.11 v2.2.3 v2.4.7)
174
+ releases = %w(v1.3.6 v1.3.7 v1.4.2 v1.5.3 v1.6.2 v1.7.2 v1.8.29 v2.0.14 v2.1.11 v2.2.3 v2.4.8)
175
175
  (branches + releases).each do |rg|
176
176
  desc "Run specs with Rubygems #{rg}"
177
177
  RSpec::Core::RakeTask.new(rg) do |t|
@@ -15,10 +15,13 @@ module Bundler
15
15
 
16
16
  def initialize(*args)
17
17
  super
18
- current_cmd = args.last[:current_command].name
18
+
19
19
  custom_gemfile = options[:gemfile] || Bundler.settings[:gemfile]
20
20
  ENV['BUNDLE_GEMFILE'] = File.expand_path(custom_gemfile) if custom_gemfile
21
+
21
22
  Bundler.settings[:retry] = options[:retry] if options[:retry]
23
+
24
+ current_cmd = args.last[:current_command].name
22
25
  auto_install if AUTO_INSTALL_CMDS.include?(current_cmd)
23
26
  rescue UnknownArgumentError => e
24
27
  raise InvalidOption, e.message
@@ -97,6 +100,7 @@ module Bundler
97
100
  "Use the specified gemfile instead of Gemfile"
98
101
  method_option "path", :type => :string, :banner =>
99
102
  "Specify a different path than the system default ($BUNDLE_PATH or $GEM_HOME). Bundler will remember this value for future installs on this machine"
103
+ map "c" => "check"
100
104
  def check
101
105
  require 'bundler/cli/check'
102
106
  Check.new(options).run
@@ -152,7 +156,7 @@ module Bundler
152
156
  "Exclude gems that are part of the specified named group."
153
157
  method_option "with", :type => :array, :banner =>
154
158
  "Include gems that are part of the specified named group."
155
-
159
+ map "i" => "install"
156
160
  def install
157
161
  require 'bundler/cli/install'
158
162
  Install.new(options.dup).run
@@ -269,6 +273,7 @@ module Bundler
269
273
  bundle exec you can require and call the bundled gems as if they were installed
270
274
  into the system wide Rubygems repository.
271
275
  D
276
+ map "e" => "exec"
272
277
  def exec(*args)
273
278
  require 'bundler/cli/exec'
274
279
  Exec.new(options, args).run
@@ -26,7 +26,7 @@ module Bundler
26
26
  Bundler.ui.error "This bundle has been frozen, but there is no Gemfile.lock present"
27
27
  exit 1
28
28
  else
29
- Bundler.load.lock unless options[:"dry-run"]
29
+ Bundler.load.lock(:preserve_bundled_with => true) unless options[:"dry-run"]
30
30
  Bundler.ui.info "The Gemfile's dependencies are satisfied"
31
31
  end
32
32
  end
@@ -1,3 +1,4 @@
1
+ require "bundler/lockfile_parser"
1
2
  require "digest/sha1"
2
3
  require "set"
3
4
 
@@ -240,14 +241,14 @@ module Bundler
240
241
  dependencies.map { |d| d.groups }.flatten.uniq
241
242
  end
242
243
 
243
- def lock(file)
244
+ def lock(file, preserve_bundled_with = false)
244
245
  contents = to_lock
245
246
 
246
247
  # Convert to \r\n if the existing lock has them
247
248
  # i.e., Windows with `git config core.autocrlf=true`
248
249
  contents.gsub!(/\n/, "\r\n") if @lockfile_contents.match("\r\n")
249
250
 
250
- return if @lockfile_contents == contents
251
+ return if lockfiles_equal?(@lockfile_contents, contents, preserve_bundled_with)
251
252
 
252
253
  if Bundler.settings[:frozen]
253
254
  Bundler.ui.error "Cannot write a changed lockfile while frozen."
@@ -658,5 +659,15 @@ module Bundler
658
659
  def requested_groups
659
660
  self.groups - Bundler.settings.without - @optional_groups + Bundler.settings.with
660
661
  end
662
+
663
+ def lockfiles_equal?(current, proposed, preserve_bundled_with)
664
+ if preserve_bundled_with
665
+ pattern = /\n\n#{LockfileParser::BUNDLED}\n\s+#{Gem::Version::VERSION_PATTERN}\n/
666
+ current.sub(pattern, "\n") == proposed.sub(pattern, "\n")
667
+ else
668
+ current == proposed
669
+ end
670
+ end
671
+
661
672
  end
662
673
  end
@@ -70,6 +70,15 @@ module Bundler
70
70
  end
71
71
  end
72
72
 
73
+ # needed for "with native extensions" during install
74
+ def extensions
75
+ if @remote_specification
76
+ @remote_specification.extensions
77
+ elsif _local_specification
78
+ _local_specification.extensions
79
+ end
80
+ end
81
+
73
82
  def _local_specification
74
83
  if @loaded_from && File.exist?(local_specification_path)
75
84
  eval(File.read(local_specification_path)).tap do |spec|
@@ -30,8 +30,8 @@ module Bundler
30
30
  @definition.current_dependencies
31
31
  end
32
32
 
33
- def lock
34
- @definition.lock(Bundler.default_lockfile)
33
+ def lock(opts = {})
34
+ @definition.lock(Bundler.default_lockfile, opts[:preserve_bundled_with])
35
35
  end
36
36
 
37
37
  def update(*gems)
@@ -39,14 +39,14 @@ def gemfile(install = false, &gemfile)
39
39
  builder.instance_eval(&gemfile)
40
40
 
41
41
  definition = builder.to_definition(nil, true)
42
- def definition.lock(file); end
42
+ def definition.lock(*); end
43
43
  definition.validate_ruby!
44
44
 
45
45
  if install
46
46
  Bundler.ui = Bundler::UI::Shell.new
47
47
  Bundler::Installer.install(Bundler.root, definition, :system => true)
48
48
  Bundler::Installer.post_install_messages.each do |name, message|
49
- Bundler.ui.info "Post install message from #{name}:\n#{message}"
49
+ Bundler.ui.info "Post-install message from #{name}:\n#{message}"
50
50
  end
51
51
  end
52
52
 
@@ -100,27 +100,18 @@ module Bundler
100
100
  def install_gem_from_spec(spec, standalone = false, worker = 0, force = false)
101
101
  # Fetch the build settings, if there are any
102
102
  settings = Bundler.settings["build.#{spec.name}"]
103
- messages = nil
104
-
105
103
  install_options = { :force => force, :ensure_builtin_gems_cached => standalone }
106
104
 
105
+ post_install_message = nil
107
106
  if settings
108
107
  # Build arguments are global, so this is mutexed
109
108
  Bundler.rubygems.with_build_args [settings] do
110
- messages = spec.source.install(spec, install_options)
109
+ post_install_message = spec.source.install(spec, install_options)
111
110
  end
112
111
  else
113
- messages = spec.source.install(spec, install_options)
112
+ post_install_message = spec.source.install(spec, install_options)
114
113
  end
115
114
 
116
- install_message, post_install_message, debug_message = *messages
117
-
118
- if install_message.include? 'Installing'
119
- Bundler.ui.confirm install_message
120
- else
121
- Bundler.ui.info install_message
122
- end
123
- Bundler.ui.debug debug_message if debug_message
124
115
  Bundler.ui.debug "#{worker}: #{spec.name} (#{spec.version}) from #{spec.loaded_from}"
125
116
 
126
117
  if Bundler.settings[:bin] && standalone
@@ -41,7 +41,7 @@ module Bundler
41
41
 
42
42
  setup_manpath
43
43
 
44
- lock
44
+ lock(:preserve_bundled_with => true)
45
45
 
46
46
  self
47
47
  end
@@ -160,18 +160,17 @@ module Bundler
160
160
  end
161
161
 
162
162
  def install(spec, force = false)
163
- debug = nil
163
+ Bundler.ui.info "Using #{version_message(spec)} from #{to_s}"
164
+
164
165
  if requires_checkout? && !@copied && !force
165
- debug = " * Checking out revision: #{ref}"
166
+ Bundler.ui.debug " * Checking out revision: #{ref}"
166
167
  git_proxy.copy_to(install_path, submodules)
167
168
  serialize_gemspecs_in(install_path)
168
169
  @copied = true
169
170
  end
170
171
  generate_bin(spec)
171
- if requires_checkout? && spec.post_install_message
172
- Installer.post_install_messages[spec.name] = spec.post_install_message
173
- end
174
- ["Using #{version_message(spec)} from #{to_s}", nil, debug]
172
+
173
+ requires_checkout? ? spec.post_install_message : nil
175
174
  end
176
175
 
177
176
  def cache(spec, custom_path = nil)
@@ -69,8 +69,9 @@ module Bundler
69
69
  end
70
70
 
71
71
  def install(spec, force = false)
72
+ Bundler.ui.info "Using #{version_message(spec)} from #{to_s}"
72
73
  generate_bin(spec, :disable_extensions)
73
- ["Using #{version_message(spec)} from #{to_s}", nil]
74
+ nil # no post-install message
74
75
  end
75
76
 
76
77
  def cache(spec, custom_path = nil)
@@ -98,8 +98,10 @@ module Bundler
98
98
  end
99
99
  end
100
100
 
101
- return ["Using #{version_message(spec)}", nil] if installed_specs[spec].any? && !force
102
-
101
+ if installed_specs[spec].any? && !force
102
+ Bundler.ui.info "Using #{version_message(spec)}"
103
+ return nil # no post-install message
104
+ end
103
105
 
104
106
  # Download the gem to get the spec, because some specs that are returned
105
107
  # by rubygems.org are broken and wrong.
@@ -115,6 +117,10 @@ module Bundler
115
117
  end
116
118
 
117
119
  unless Bundler.settings[:no_install]
120
+ message = "Installing #{version_message(spec)}"
121
+ message << " with native extensions" if spec.extensions.any?
122
+ Bundler.ui.confirm message
123
+
118
124
  path = cached_gem(spec)
119
125
  if Bundler.requires_sudo?
120
126
  install_path = Bundler.tmp(spec.full_name)
@@ -158,7 +164,8 @@ module Bundler
158
164
  installed_spec.loaded_from = loaded_from(spec)
159
165
  end
160
166
  spec.loaded_from = loaded_from(spec)
161
- ["Installing #{version_message(spec)}", spec.post_install_message]
167
+
168
+ spec.post_install_message
162
169
  ensure
163
170
  Bundler.rm_rf(install_path) if Bundler.requires_sudo?
164
171
  end
@@ -10,11 +10,7 @@ module Bundler
10
10
  end
11
11
 
12
12
  def say(message)
13
- if message =~ /native extensions/
14
- @ui.info "with native extensions "
15
- else
16
- @ui.debug(message)
17
- end
13
+ @ui && @ui.debug(message)
18
14
  end
19
15
  end
20
16
  end
@@ -2,5 +2,5 @@ module Bundler
2
2
  # We're doing this because we might write tests that deal
3
3
  # with other versions of bundler and we are unsure how to
4
4
  # handle this better.
5
- VERSION = "1.10.3" unless defined?(::Bundler::VERSION)
5
+ VERSION = "1.10.4" unless defined?(::Bundler::VERSION)
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bundler
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.10.3
4
+ version: 1.10.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - André Arko
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2015-06-04 00:00:00.000000000 Z
14
+ date: 2015-06-16 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: mustache
@@ -316,9 +316,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
316
316
  version: 1.3.6
317
317
  requirements: []
318
318
  rubyforge_project:
319
- rubygems_version: 2.4.7
319
+ rubygems_version: 2.4.5
320
320
  signing_key:
321
321
  specification_version: 4
322
322
  summary: The best way to manage your application's dependencies
323
323
  test_files: []
324
- has_rdoc: