mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Revert r42938 "* lib/rubygems: Update to RubyGems 2.1.3"
It breaks build.
20130913
T200302Z.diff.html.gz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42941 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2614d9ba2f
commit
269503b544
110 changed files with 4928 additions and 3479 deletions
|
@ -28,6 +28,16 @@ class Gem::Commands::FetchCommand < Gem::Command
|
|||
"--version '#{Gem::Requirement.default}'"
|
||||
end
|
||||
|
||||
def description # :nodoc:
|
||||
<<-EOF
|
||||
The fetch command fetches gem files that can be stored for later use or
|
||||
unpacked to examine their contents.
|
||||
|
||||
See the build command help for an example of unpacking a gem, modifying it,
|
||||
then repackaging it.
|
||||
EOF
|
||||
end
|
||||
|
||||
def usage # :nodoc:
|
||||
"#{program_name} GEMNAME [GEMNAME ...]"
|
||||
end
|
||||
|
@ -42,13 +52,15 @@ class Gem::Commands::FetchCommand < Gem::Command
|
|||
dep = Gem::Dependency.new gem_name, version
|
||||
dep.prerelease = options[:prerelease]
|
||||
|
||||
specs_and_sources, errors = Gem::SpecFetcher.fetcher.spec_for_dependency dep
|
||||
specs_and_sources, errors =
|
||||
Gem::SpecFetcher.fetcher.spec_for_dependency dep
|
||||
|
||||
if platform then
|
||||
filtered = specs_and_sources.select { |s,| s.platform == platform }
|
||||
specs_and_sources = filtered unless filtered.empty?
|
||||
end
|
||||
|
||||
spec, source = specs_and_sources.sort_by { |s,| s.version }.first
|
||||
spec, source = specs_and_sources.max_by { |s,| s.version }
|
||||
|
||||
if spec.nil? then
|
||||
show_lookup_failure gem_name, version, errors, options[:domain]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue