[Rubygems-developers] Customising Rubygems for Debian/Ubuntu.
Eric Hodel
drbrain at segment7.net
Mon Jun 30 18:46:43 EDT 2008
On Jun 27, 2008, at 01:14 AM, Neil Wilson wrote:
> 2008/6/27 Eric Hodel <drbrain at segment7.net>:
>> Is this for `gem` itself or for a gem-installed executable?
>
> It is for the gem installed exectuable. Gem would install, say,
> 'mongrel_rails1.8' and then call 'update-alternatives' so that the
> alternatives system creates the necessary symlinks allowing the user
> to run 'mongrel_rails'.
Ok.
In r1829 I have added:
Gem.pre_install
Gem.post_install
Gem.pre_uninstall
Gem.post_uninstall
each takes a block that is saved then called with the Gem::Installer/
Gem::Uninstaller instance for the gem being installed/uninstalled at
the appropriate time. Multiple pre/post install hooks are supported.
Gem.post_install do |installer|
puts "!!! #{installer.spec.full_name} INSTALLED !!!"
end
Gem.post_uninstall do |uninstaller|
puts "!!! #{uninstaller.spec.full_name} UNINSTALLED !!!"
end
More information about the Rubygems-developers
mailing list