lib/bundler.rb in bundler-2.2.0 vs lib/bundler.rb in bundler-2.2.1
- old
+ new
@@ -210,10 +210,19 @@
lock = Bundler.read_file(Bundler.default_lockfile)
LockfileParser.new(lock)
end
end
+ def locked_bundler_version
+ return nil unless defined?(@definition) && @definition
+
+ locked_gems = definition.locked_gems
+ return nil unless locked_gems
+
+ locked_gems.bundler_version
+ end
+
def ruby_scope
"#{Bundler.rubygems.ruby_engine}/#{RbConfig::CONFIG["ruby_version"]}"
end
def user_home
@@ -600,11 +609,12 @@
reset_paths!
Plugin.reset!
reset_rubygems!
end
- def reset_settings!
+ def reset_settings_and_root!
@settings = nil
+ @root = nil
end
def reset_paths!
@bin_path = nil
@bundler_major_version = nil