On Jul 1, 2008, at 01:14 AM, Neil Wilson wrote:
2008/6/30 Eric Hodel <[EMAIL PROTECTED]>:
Ok.

In r1829 I have added:

Gem.pre_install
Gem.post_install
Gem.pre_uninstall
Gem.post_uninstall

Thanks for that Eric. I'll have a play.

Do I define these in the 'operating_system.rb' file, or elsewhere? And
I presume they act on all gems installed/uninstalled on a system (ie
the hook isn't specific to a gem and stored in the gem package
somewhere).

You would define what you need in operating_system.rb.

These hooks are only available for packagers and implementors, gems themselves cannot define any hooks.

One note I forgot to make was that they are called regardless of installation path, so if I run `gem install some_gem -i ~/tmp/gems` you may not want to update alternatives. (Rubinius will take advantage of these to compile all the .rb files, for example).

Since I just remembered this, I added #bin_dir and #gem_home to Installer and Uninstaller so you can determine whether or not to run update alternatives.
_______________________________________________
Rubygems-developers mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/rubygems-developers

Reply via email to