summaryrefslogtreecommitdiff
path: root/lib/rubygems/commands
diff options
context:
space:
mode:
-rw-r--r--lib/rubygems/commands/pristine_command.rb16
-rw-r--r--lib/rubygems/commands/uninstall_command.rb2
2 files changed, 16 insertions, 2 deletions
@@ -109,6 +109,11 @@ extensions will be restored.
next
end
unless spec.extensions.empty? or options[:extensions] then
say "Skipped #{spec.full_name}, it needs to compile an extension"
next
@@ -120,8 +125,17 @@ extensions will be restored.
require 'rubygems/remote_fetcher'
say "Cached gem for #{spec.full_name} not found, attempting to fetch..."
dep = Gem::Dependency.new spec.name, spec.version
- Gem::RemoteFetcher.fetcher.download_to_cache dep
end
env_shebang =
@@ -124,7 +124,7 @@ that is a dependency of an existing gem. You can use the
end
def uninstall_all
- _, specs = Gem::Specification.partition { |spec| spec.default_gem? }
specs.each do |spec|
options[:version] = spec.version