End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
instance method
Gem::Resolver::ActivationRequest#download
download(path)
lib/rubygems/resolver/activation_request.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.0.5/lib/rubygems/resolver/activation_request.rb, line 55
def download(path)
Gem.ensure_gem_subdirectories path
if @spec.respond_to? :sources
exception = nil
path = @spec.sources.find do |source|
begin
source.download full_spec, path
rescue exception
end
end
return path if path
raise exception if exception
elsif @spec.respond_to? :source
source = @spec.source
source.download full_spec, path
else
source = Gem.sources.first
source.download full_spec, path
end
end
Downloads a gem at path and returns the file path.