mirror of
https://github.com/ruby/ruby.git
synced 2025-09-21 03:24:00 +02:00
Merge RubyGems-3.3.8 and Bundler-2.3.8
This commit is contained in:
parent
1a6a608ae0
commit
b5ef64a8a1
38 changed files with 118 additions and 39 deletions
|
@ -782,6 +782,7 @@ module Bundler
|
||||||
else
|
else
|
||||||
{ :default => Source::RubygemsAggregate.new(sources, source_map) }.merge(source_map.direct_requirements)
|
{ :default => Source::RubygemsAggregate.new(sources, source_map) }.merge(source_map.direct_requirements)
|
||||||
end
|
end
|
||||||
|
source_requirements.merge!(source_map.locked_requirements) unless @remote
|
||||||
metadata_dependencies.each do |dep|
|
metadata_dependencies.each do |dep|
|
||||||
source_requirements[dep.name] = sources.metadata_source
|
source_requirements[dep.name] = sources.metadata_source
|
||||||
end
|
end
|
||||||
|
@ -828,7 +829,7 @@ module Bundler
|
||||||
end
|
end
|
||||||
|
|
||||||
def source_map
|
def source_map
|
||||||
@source_map ||= SourceMap.new(sources, dependencies)
|
@source_map ||= SourceMap.new(sources, dependencies, @locked_specs)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-ADD" "1" "December 2021" "" ""
|
.TH "BUNDLE\-ADD" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-add\fR \- Add gem to the Gemfile and run bundle install
|
\fBbundle\-add\fR \- Add gem to the Gemfile and run bundle install
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-BINSTUBS" "1" "December 2021" "" ""
|
.TH "BUNDLE\-BINSTUBS" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-binstubs\fR \- Install the binstubs of the listed gems
|
\fBbundle\-binstubs\fR \- Install the binstubs of the listed gems
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-CACHE" "1" "December 2021" "" ""
|
.TH "BUNDLE\-CACHE" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-cache\fR \- Package your needed \fB\.gem\fR files into your application
|
\fBbundle\-cache\fR \- Package your needed \fB\.gem\fR files into your application
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-CHECK" "1" "December 2021" "" ""
|
.TH "BUNDLE\-CHECK" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-check\fR \- Verifies if dependencies are satisfied by installed gems
|
\fBbundle\-check\fR \- Verifies if dependencies are satisfied by installed gems
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-CLEAN" "1" "December 2021" "" ""
|
.TH "BUNDLE\-CLEAN" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-clean\fR \- Cleans up unused gems in your bundler directory
|
\fBbundle\-clean\fR \- Cleans up unused gems in your bundler directory
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-CONFIG" "1" "December 2021" "" ""
|
.TH "BUNDLE\-CONFIG" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-config\fR \- Set bundler configuration options
|
\fBbundle\-config\fR \- Set bundler configuration options
|
||||||
|
@ -83,7 +83,7 @@ A space\-separated list of groups referencing gems to skip during installation\.
|
||||||
.
|
.
|
||||||
.TP
|
.TP
|
||||||
\fBwith\fR
|
\fBwith\fR
|
||||||
A space\-separated list of groups referencing gems to include during installation\.
|
A space\-separated list of \fBoptional\fR groups referencing gems to include during installation\.
|
||||||
.
|
.
|
||||||
.SH "BUILD OPTIONS"
|
.SH "BUILD OPTIONS"
|
||||||
You can use \fBbundle config\fR to give Bundler the flags to pass to the gem installer every time bundler tries to install a particular gem\.
|
You can use \fBbundle config\fR to give Bundler the flags to pass to the gem installer every time bundler tries to install a particular gem\.
|
||||||
|
|
|
@ -83,7 +83,7 @@ The options that can be configured are:
|
||||||
A space-separated list of groups referencing gems to skip during installation.
|
A space-separated list of groups referencing gems to skip during installation.
|
||||||
|
|
||||||
* `with`:
|
* `with`:
|
||||||
A space-separated list of groups referencing gems to include during installation.
|
A space-separated list of **optional** groups referencing gems to include during installation.
|
||||||
|
|
||||||
## BUILD OPTIONS
|
## BUILD OPTIONS
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-DOCTOR" "1" "December 2021" "" ""
|
.TH "BUNDLE\-DOCTOR" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-doctor\fR \- Checks the bundle for common problems
|
\fBbundle\-doctor\fR \- Checks the bundle for common problems
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-EXEC" "1" "December 2021" "" ""
|
.TH "BUNDLE\-EXEC" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-exec\fR \- Execute a command in the context of the bundle
|
\fBbundle\-exec\fR \- Execute a command in the context of the bundle
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-GEM" "1" "December 2021" "" ""
|
.TH "BUNDLE\-GEM" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-gem\fR \- Generate a project skeleton for creating a rubygem
|
\fBbundle\-gem\fR \- Generate a project skeleton for creating a rubygem
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-INFO" "1" "December 2021" "" ""
|
.TH "BUNDLE\-INFO" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-info\fR \- Show information for the given gem in your bundle
|
\fBbundle\-info\fR \- Show information for the given gem in your bundle
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-INIT" "1" "December 2021" "" ""
|
.TH "BUNDLE\-INIT" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-init\fR \- Generates a Gemfile into the current working directory
|
\fBbundle\-init\fR \- Generates a Gemfile into the current working directory
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-INJECT" "1" "December 2021" "" ""
|
.TH "BUNDLE\-INJECT" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-inject\fR \- Add named gem(s) with version requirements to Gemfile
|
\fBbundle\-inject\fR \- Add named gem(s) with version requirements to Gemfile
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-INSTALL" "1" "December 2021" "" ""
|
.TH "BUNDLE\-INSTALL" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-install\fR \- Install the dependencies specified in your Gemfile
|
\fBbundle\-install\fR \- Install the dependencies specified in your Gemfile
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-LIST" "1" "December 2021" "" ""
|
.TH "BUNDLE\-LIST" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-list\fR \- List all the gems in the bundle
|
\fBbundle\-list\fR \- List all the gems in the bundle
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-LOCK" "1" "December 2021" "" ""
|
.TH "BUNDLE\-LOCK" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-lock\fR \- Creates / Updates a lockfile without installing
|
\fBbundle\-lock\fR \- Creates / Updates a lockfile without installing
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-OPEN" "1" "December 2021" "" ""
|
.TH "BUNDLE\-OPEN" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-open\fR \- Opens the source directory for a gem in your bundle
|
\fBbundle\-open\fR \- Opens the source directory for a gem in your bundle
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-OUTDATED" "1" "December 2021" "" ""
|
.TH "BUNDLE\-OUTDATED" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-outdated\fR \- List installed gems with newer versions available
|
\fBbundle\-outdated\fR \- List installed gems with newer versions available
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-PLATFORM" "1" "December 2021" "" ""
|
.TH "BUNDLE\-PLATFORM" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-platform\fR \- Displays platform compatibility information
|
\fBbundle\-platform\fR \- Displays platform compatibility information
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-PRISTINE" "1" "December 2021" "" ""
|
.TH "BUNDLE\-PRISTINE" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-pristine\fR \- Restores installed gems to their pristine condition
|
\fBbundle\-pristine\fR \- Restores installed gems to their pristine condition
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-REMOVE" "1" "December 2021" "" ""
|
.TH "BUNDLE\-REMOVE" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-remove\fR \- Removes gems from the Gemfile
|
\fBbundle\-remove\fR \- Removes gems from the Gemfile
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-SHOW" "1" "December 2021" "" ""
|
.TH "BUNDLE\-SHOW" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-show\fR \- Shows all the gems in your bundle, or the path to a gem
|
\fBbundle\-show\fR \- Shows all the gems in your bundle, or the path to a gem
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-UPDATE" "1" "December 2021" "" ""
|
.TH "BUNDLE\-UPDATE" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-update\fR \- Update your gems to the latest available versions
|
\fBbundle\-update\fR \- Update your gems to the latest available versions
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE\-VIZ" "1" "December 2021" "" ""
|
.TH "BUNDLE\-VIZ" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\-viz\fR \- Generates a visual dependency graph for your Gemfile
|
\fBbundle\-viz\fR \- Generates a visual dependency graph for your Gemfile
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "BUNDLE" "1" "December 2021" "" ""
|
.TH "BUNDLE" "1" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBbundle\fR \- Ruby Dependency Management
|
\fBbundle\fR \- Ruby Dependency Management
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
.\" generated with Ronn/v0.7.3
|
.\" generated with Ronn/v0.7.3
|
||||||
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
||||||
.
|
.
|
||||||
.TH "GEMFILE" "5" "December 2021" "" ""
|
.TH "GEMFILE" "5" "February 2022" "" ""
|
||||||
.
|
.
|
||||||
.SH "NAME"
|
.SH "NAME"
|
||||||
\fBGemfile\fR \- A format for describing gem dependencies for Ruby programs
|
\fBGemfile\fR \- A format for describing gem dependencies for Ruby programs
|
||||||
|
|
|
@ -141,7 +141,7 @@ module Bundler
|
||||||
end
|
end
|
||||||
return unless multiple_gemfiles
|
return unless multiple_gemfiles
|
||||||
message = "Multiple gemfiles (gems.rb and Gemfile) detected. " \
|
message = "Multiple gemfiles (gems.rb and Gemfile) detected. " \
|
||||||
"Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.rb.locked."
|
"Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.locked."
|
||||||
Bundler.ui.warn message
|
Bundler.ui.warn message
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -2,11 +2,12 @@
|
||||||
|
|
||||||
module Bundler
|
module Bundler
|
||||||
class SourceMap
|
class SourceMap
|
||||||
attr_reader :sources, :dependencies
|
attr_reader :sources, :dependencies, :locked_specs
|
||||||
|
|
||||||
def initialize(sources, dependencies)
|
def initialize(sources, dependencies, locked_specs)
|
||||||
@sources = sources
|
@sources = sources
|
||||||
@dependencies = dependencies
|
@dependencies = dependencies
|
||||||
|
@locked_specs = locked_specs
|
||||||
end
|
end
|
||||||
|
|
||||||
def pinned_spec_names(skip = nil)
|
def pinned_spec_names(skip = nil)
|
||||||
|
@ -54,5 +55,17 @@ module Bundler
|
||||||
requirements
|
requirements
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def locked_requirements
|
||||||
|
@locked_requirements ||= begin
|
||||||
|
requirements = {}
|
||||||
|
locked_specs.each do |locked_spec|
|
||||||
|
source = locked_spec.source
|
||||||
|
source.add_dependency_names(locked_spec.name)
|
||||||
|
requirements[locked_spec.name] = source
|
||||||
|
end
|
||||||
|
requirements
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
# frozen_string_literal: false
|
# frozen_string_literal: false
|
||||||
|
|
||||||
module Bundler
|
module Bundler
|
||||||
VERSION = "2.3.7".freeze
|
VERSION = "2.3.8".freeze
|
||||||
|
|
||||||
def self.bundler_major_version
|
def self.bundler_major_version
|
||||||
@bundler_major_version ||= VERSION.split(".").first.to_i
|
@bundler_major_version ||= VERSION.split(".").first.to_i
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
require 'rbconfig'
|
require 'rbconfig'
|
||||||
|
|
||||||
module Gem
|
module Gem
|
||||||
VERSION = "3.3.7".freeze
|
VERSION = "3.3.8".freeze
|
||||||
end
|
end
|
||||||
|
|
||||||
# Must be first since it unloads the prelude from 1.9.2
|
# Must be first since it unloads the prelude from 1.9.2
|
||||||
|
|
|
@ -431,6 +431,69 @@ RSpec.describe "bundle check" do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
context "with gemspec directive and scoped sources" do
|
||||||
|
before do
|
||||||
|
build_repo4 do
|
||||||
|
build_gem "awesome_print"
|
||||||
|
end
|
||||||
|
|
||||||
|
build_repo2 do
|
||||||
|
build_gem "dex-dispatch-engine"
|
||||||
|
end
|
||||||
|
|
||||||
|
build_lib("bundle-check-issue", :path => tmp.join("bundle-check-issue")) do |s|
|
||||||
|
s.write "Gemfile", <<-G
|
||||||
|
source "https://localgemserver.test"
|
||||||
|
|
||||||
|
gemspec
|
||||||
|
|
||||||
|
source "https://localgemserver.test/extra" do
|
||||||
|
gem "dex-dispatch-engine"
|
||||||
|
end
|
||||||
|
G
|
||||||
|
|
||||||
|
s.add_dependency "awesome_print"
|
||||||
|
end
|
||||||
|
|
||||||
|
bundle "install", :artifice => "compact_index_extra", :env => { "BUNDLER_SPEC_GEM_REPO" => gem_repo4.to_s }, :dir => tmp.join("bundle-check-issue")
|
||||||
|
end
|
||||||
|
|
||||||
|
it "does not corrupt lockfile when changing version" do
|
||||||
|
version_file = tmp.join("bundle-check-issue/bundle-check-issue.gemspec")
|
||||||
|
File.write(version_file, File.read(version_file).gsub(/s\.version = .+/, "s.version = '9999'"))
|
||||||
|
|
||||||
|
bundle "check --verbose", :dir => tmp.join("bundle-check-issue")
|
||||||
|
|
||||||
|
expect(File.read(tmp.join("bundle-check-issue/Gemfile.lock"))).to eq <<~L
|
||||||
|
PATH
|
||||||
|
remote: .
|
||||||
|
specs:
|
||||||
|
bundle-check-issue (9999)
|
||||||
|
awesome_print
|
||||||
|
|
||||||
|
GEM
|
||||||
|
remote: https://localgemserver.test/
|
||||||
|
specs:
|
||||||
|
awesome_print (1.0)
|
||||||
|
|
||||||
|
GEM
|
||||||
|
remote: https://localgemserver.test/extra/
|
||||||
|
specs:
|
||||||
|
dex-dispatch-engine (1.0)
|
||||||
|
|
||||||
|
PLATFORMS
|
||||||
|
#{lockfile_platforms}
|
||||||
|
|
||||||
|
DEPENDENCIES
|
||||||
|
bundle-check-issue!
|
||||||
|
dex-dispatch-engine!
|
||||||
|
|
||||||
|
BUNDLED WITH
|
||||||
|
#{Bundler::VERSION}
|
||||||
|
L
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
describe "BUNDLED WITH" do
|
describe "BUNDLED WITH" do
|
||||||
def lock_with(bundler_version = nil)
|
def lock_with(bundler_version = nil)
|
||||||
lock = <<~L
|
lock = <<~L
|
||||||
|
|
|
@ -352,7 +352,7 @@ RSpec.describe "major deprecations" do
|
||||||
G
|
G
|
||||||
|
|
||||||
expect(warnings).to include(
|
expect(warnings).to include(
|
||||||
"Multiple gemfiles (gems.rb and Gemfile) detected. Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.rb.locked."
|
"Multiple gemfiles (gems.rb and Gemfile) detected. Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.locked."
|
||||||
)
|
)
|
||||||
|
|
||||||
expect(the_bundle).not_to include_gem "rack 1.0"
|
expect(the_bundle).not_to include_gem "rack 1.0"
|
||||||
|
@ -512,7 +512,7 @@ RSpec.describe "major deprecations" do
|
||||||
|
|
||||||
it "should print a single deprecation warning" do
|
it "should print a single deprecation warning" do
|
||||||
expect(warnings).to include(
|
expect(warnings).to include(
|
||||||
"Multiple gemfiles (gems.rb and Gemfile) detected. Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.rb.locked."
|
"Multiple gemfiles (gems.rb and Gemfile) detected. Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.locked."
|
||||||
)
|
)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -274,6 +274,8 @@ class TestGemCommandsSetupCommand < Gem::TestCase
|
||||||
spec.executables.each do |e|
|
spec.executables.each do |e|
|
||||||
assert_path_exist File.join destdir, @gemhome.gsub(/^[a-zA-Z]:/, ''), 'gems', spec.full_name, spec.bindir, e
|
assert_path_exist File.join destdir, @gemhome.gsub(/^[a-zA-Z]:/, ''), 'gems', spec.full_name, spec.bindir, e
|
||||||
end
|
end
|
||||||
|
ensure
|
||||||
|
FileUtils.chmod "+w", @gemhome
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_install_default_bundler_gem_with_destdir_and_prefix_flags
|
def test_install_default_bundler_gem_with_destdir_and_prefix_flags
|
||||||
|
|
|
@ -72,4 +72,4 @@ DEPENDENCIES
|
||||||
webrick (~> 1.6)
|
webrick (~> 1.6)
|
||||||
|
|
||||||
BUNDLED WITH
|
BUNDLED WITH
|
||||||
2.3.7
|
2.3.8
|
||||||
|
|
|
@ -61,4 +61,4 @@ DEPENDENCIES
|
||||||
test-unit
|
test-unit
|
||||||
|
|
||||||
BUNDLED WITH
|
BUNDLED WITH
|
||||||
2.3.7
|
2.3.8
|
||||||
|
|
|
@ -67,4 +67,4 @@ DEPENDENCIES
|
||||||
test-unit
|
test-unit
|
||||||
|
|
||||||
BUNDLED WITH
|
BUNDLED WITH
|
||||||
2.3.7
|
2.3.8
|
||||||
|
|
|
@ -41,4 +41,4 @@ DEPENDENCIES
|
||||||
webrick (= 1.7.0)
|
webrick (= 1.7.0)
|
||||||
|
|
||||||
BUNDLED WITH
|
BUNDLED WITH
|
||||||
2.3.7
|
2.3.8
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue