Class Gem::Uninstaller
In: lib/rubygems/uninstaller.rb
Parent: Object

An Uninstaller.

The uninstaller fires pre and post uninstall hooks. Hooks can be added either through a rubygems_plugin.rb file in an installed gem or via a rubygems/defaults/#{RUBY_ENGINE}.rb or rubygems/defaults/operating_system.rb file. See Gem.pre_uninstall and Gem.post_uninstall for details.

Methods

Included Modules

Gem::UserInteraction

Attributes

bin_dir  [R]  The directory a gem‘s executables will be installed into
gem_home  [R]  The gem repository the gem will be installed into
spec  [R]  The Gem::Specification for the gem being uninstalled, only set during uninstall_gem

Public Class methods

Constructs an uninstaller that will uninstall gem

Public Instance methods

Is spec in gem_dir?

spec:the spec of the gem to be uninstalled
list:the list of all such gems

Warning: this method modifies the list parameter. Once it has uninstalled a gem, it is removed from that list.

Removes all gems in list.

NOTE: removes uninstalled gems from list.

Removes installed executables and batch files (windows only) for gemspec.

Performs the uninstall of the gem. This removes the spec, the Gem directory, and the cached .gem file.

Uninstalls gem spec

[Validate]