Best practice: installing plugin assets in rake task or inst

I noticed that a few plugins come with rake tasks to install additional
assets. In Rails 1.1.4 there’s a hook file, install.rb, that is run
when after the plugin has been installed (edge Rails has uninstall.rb,
too). Wouldn’t it be nicer to use this (these) hooks to install
(remove) plugin specific files automatically?

Preferrably existing (different) files are overwritten only after asking
and removed only when unchanged.

Also, I saw that several plugin READMEs tell the plugin user to include
JavaScript files in their views or layouts. This isn’t necessary as it
can be automated:


After this, <%= javascript_include_tag :default %> will additionally
write out an include element for public/javascripts/cool_plugin.js


Michael S.
mailto:[email protected]