bundler 1.15.0 → 1.15.1

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: 4c9f315a84cc713eb5c8e32ac8d6adb2c79616c9
4
- data.tar.gz: d89692edcbf19e5232655a26b3f080917490ab8d
3
+ metadata.gz: a6aa71f486e6b4b5d1692c18491fcb29101802c4
4
+ data.tar.gz: b2fab0763dac40223188dd8fdfc4d662693d6be3
5
5
  SHA512:
6
- metadata.gz: 78bbfc567097d4d04dbf0c4f4aadfd7a34c109e154e5c910b648723122247e532ef307cc3871a430af0b7b9155c01d5473355c80709eba00fc402a11669f4d47
7
- data.tar.gz: 8a3f40a299f1910aa7a495c08138e1c3c76f6a5bda3a035e3239a08bab906999013cf98ad72244fc4558128649f106bddc37c8a2c330e9ce82b7f194eb4cbe1e
6
+ metadata.gz: b2aaf805b52b9bfef1c380f9ea835d0b7fefb8aa4962b8b5706f24fe23ff4ebbf3eb2b58a51d1dfc8fa228d3ce0b5a8a260b37028b8a9ca58451b3f4615a9d13
7
+ data.tar.gz: 36eb16b2c3e86df6010ea8623260c61ac1b82f4333fb69d091839e263aa7e49d1d35bd3fc831c283bb2b732b7405db08fb8668c03fb47ebb9256ae62e1019eaf
@@ -1,3 +1,12 @@
1
+ ## 1.15.1 (2017-06-02)
2
+
3
+ Bugfixes:
4
+
5
+ - `bundle lock --update GEM` will fail gracefully when the gem is not in the lockfile (#5693, @segiddins)
6
+ - `bundle init --gemspec` will fail gracefully when the gemspec is invalid (@colby-swandale)
7
+ - `bundle install --force` works when the gemfile contains git gems (#5678, @segiddins)
8
+ - `bundle env` will print well-formed markdown when there are no settings (#5677, @segiddins)
9
+
1
10
  ## 1.15.0 (2017-05-19)
2
11
 
3
12
  This space intentionally left blank.
@@ -70,6 +70,13 @@ module Bundler
70
70
  message
71
71
  end
72
72
 
73
+ def self.ensure_all_gems_in_lockfile!(names, locked_gems = Bundler.locked_gems)
74
+ locked_names = locked_gems.specs.map(&:name)
75
+ names.-(locked_names).each do |g|
76
+ raise GemNotFound, gem_not_found_message(g, locked_names)
77
+ end
78
+ end
79
+
73
80
  def self.configure_gem_version_promoter(definition, options)
74
81
  patch_level = patch_level_options(options)
75
82
  raise InvalidOption, "Provide only one of the following options: #{patch_level.join(", ")}" unless patch_level.length <= 1
@@ -18,7 +18,9 @@ module Bundler
18
18
  Bundler.ui.error "Gem specification #{gemspec} doesn't exist"
19
19
  exit 1
20
20
  end
21
- spec = Gem::Specification.load(gemspec)
21
+
22
+ spec = Bundler.load_gemspec_uncached(gemspec)
23
+
22
24
  puts "Writing new Gemfile to #{SharedHelpers.pwd}/Gemfile"
23
25
  File.open("Gemfile", "wb") do |file|
24
26
  file << "# Generated from #{gemspec}\n"
@@ -22,7 +22,10 @@ module Bundler
22
22
  Bundler::Fetcher.disable_endpoint = options["full-index"]
23
23
 
24
24
  update = options[:update]
25
- update = { :gems => update, :lock_shared_dependencies => options[:conservative] } if update.is_a?(Array)
25
+ if update.is_a?(Array) # unlocking specific gems
26
+ Bundler::CLI::Common.ensure_all_gems_in_lockfile!(update)
27
+ update = { :gems => update, :lock_shared_dependencies => options[:conservative] }
28
+ end
26
29
  definition = Bundler.definition(update)
27
30
 
28
31
  Bundler::CLI::Common.configure_gem_version_promoter(Bundler.definition, options) if options[:update]
@@ -25,12 +25,7 @@ module Bundler
25
25
  raise GemfileLockNotFound, "This Bundle hasn't been installed yet. " \
26
26
  "Run `bundle install` to update and install the bundled gems."
27
27
  end
28
- # cycle through the requested gems, to make sure they exist
29
- names = Bundler.locked_gems.specs.map(&:name)
30
- gems.each do |g|
31
- next if names.include?(g)
32
- raise GemNotFound, Bundler::CLI::Common.gem_not_found_message(g, names)
33
- end
28
+ Bundler::CLI::Common.ensure_all_gems_in_lockfile!(gems)
34
29
 
35
30
  if groups.any?
36
31
  specs = Bundler.definition.specs_for groups
@@ -29,14 +29,16 @@ module Bundler
29
29
 
30
30
  out << "```\n"
31
31
 
32
- out << "\n## Bundler settings\n\n```\n" unless Bundler.settings.all.empty?
33
- Bundler.settings.all.each do |setting|
34
- out << setting << "\n"
35
- Bundler.settings.pretty_values_for(setting).each do |line|
36
- out << " " << line << "\n"
32
+ unless Bundler.settings.all.empty?
33
+ out << "\n## Bundler settings\n\n```\n"
34
+ Bundler.settings.all.each do |setting|
35
+ out << setting << "\n"
36
+ Bundler.settings.pretty_values_for(setting).each do |line|
37
+ out << " " << line << "\n"
38
+ end
37
39
  end
40
+ out << "```\n"
38
41
  end
39
- out << "```\n"
40
42
 
41
43
  return out unless SharedHelpers.in_bundle?
42
44
 
@@ -212,7 +212,7 @@ module Bundler
212
212
  end
213
213
 
214
214
  def resolve_if_need(options)
215
- if !options["update"] && !options[:inline] && Bundler.default_lockfile.file?
215
+ if !options["update"] && !options[:inline] && !options["force"] && Bundler.default_lockfile.file?
216
216
  local = Bundler.ui.silence do
217
217
  begin
218
218
  tmpdef = Definition.build(Bundler.default_gemfile, Bundler.default_lockfile, nil)
@@ -3,7 +3,7 @@ require "shellwords"
3
3
  require "tempfile"
4
4
  module Bundler
5
5
  class Source
6
- class Git < Path
6
+ class Git
7
7
  class GitNotInstalledError < GitError
8
8
  def initialize
9
9
  msg = String.new
@@ -132,7 +132,7 @@ module Bundler
132
132
  if submodules
133
133
  git_retry "submodule update --init --recursive"
134
134
  elsif Gem::Version.create(version) >= Gem::Version.create("2.9.0")
135
- git_retry "submodule deinit --all"
135
+ git_retry "submodule deinit --all --force"
136
136
  end
137
137
  end
138
138
  end
@@ -7,7 +7,7 @@ module Bundler
7
7
  # We're doing this because we might write tests that deal
8
8
  # with other versions of bundler and we are unsure how to
9
9
  # handle this better.
10
- VERSION = "1.15.0" unless defined?(::Bundler::VERSION)
10
+ VERSION = "1.15.1" unless defined?(::Bundler::VERSION)
11
11
 
12
12
  def self.overwrite_loaded_gem_version
13
13
  begin
@@ -48,6 +48,9 @@ We divide `bundle` subcommands into primary commands and utilities.
48
48
 
49
49
  ## UTILITIES
50
50
 
51
+ * `bundle add(1)`:
52
+ Add the named gem to the Gemfile and run `bundle install`
53
+
51
54
  * `bundle binstubs(1)`:
52
55
  Generate binstubs for executables in a gem
53
56
 
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.15.0
4
+ version: 1.15.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - André Arko
@@ -17,7 +17,7 @@ authors:
17
17
  autorequire:
18
18
  bindir: exe
19
19
  cert_chain: []
20
- date: 2017-05-19 00:00:00.000000000 Z
20
+ date: 2017-06-02 00:00:00.000000000 Z
21
21
  dependencies:
22
22
  - !ruby/object:Gem::Dependency
23
23
  name: automatiek