is there a way to not repeat installing plugins?

Check out the GemsOnRails project. I included it in my list of 5 Gems you might not know about but should:

http://anthonyeden.com/2006/12/20/gems-you-might-not-know-about-but-should

This assumes of course that the plugin is available as a gem. If not, poke the author and tell them they should make it a gem. :slight_smile:

V/r Anthony

I think the OP asked a slightly different question (although this is a very valuable answer). The way I read the question it was, "say I always start out with the same set of base plugins -- say engines, login_engine, user_engine, exception_notification, ez_where. Does anyone know an elegant way to press a magic button to achieve a base plugin configuration much as 'rails foo' achieves a base Rails app configuration.

Just my interpretation of the question.

--steve

use svn[1] to install the plugin - then when you install, the svn checkout will extract the external references to your plugin directory.

script/plugin install -X can be used to setup the svn externals reference, or you can use "svn propedit svn:externals vendor/plugin" to define all the external refs. The benefit you have here is you can 'freeze' to specific version of a plugin - which comes in real handy when you're mirroring production in your tests.

[1] http://svnbook.red-bean.com/

Cheers, Jodi General Partner The nNovation Group inc. www.nnovation.ca/blog

I think something more along these lines would be a start toward what the OP was looking for:

# Yikes! Hard coded stuff. Put your stock plugins here {      "exception_notification" => "http://dev.rubyonrails.org/svn/ rails/plugins/exception_notification/",      "acts_as_authenticated" => "http://svn.techno-weenie.net/ projects/plugins/acts_as_authenticated",      "rspec" => "svn://rubyforge.org/var/svn/rspec/ tags/REL_0_7_4/vendor/rspec_on_rails/vendor/plugins/rspec" }.each_pair do |plugin, repos|      force = ''      if File.exist?("vendor/plugins/#{plugin}")          puts "Plugin #{plugin} appears to be installed already. Force? [yN]"          next if gets.downcase != 'y'          force = ' --force'      end      system("script/plugin install #{repos} #{plugin}#{force}") end # ------------------------------------------------------

Clearly, this was a quick hack, but it will install a base set of plugins from their repositories. TODOs would be to install them as svn externals and/or add to repository.

Thoughts?

Correction. Line 9 should read:

         next if gets.downcase.strip != 'y'

--steve

Steve,

I like it. How about making it so the plugin list is a simple text file somewhere and then making a Rake task which will handle the installation?

V/r Anthony

Ok, there's a rake task on:

http://rtfm.calicowebdev.com/2006/12/24/installing-stock-plugins

Steve

There is a replacement for the plugin script called Rapt: http://rapt.rubyforge.org/

Rapt has the concept of a "plugin pack", that is a set of plugins you can install in one swell foop.

I've never used this functionality

http://blog.hasmanythrough.com/2006/12/28/stop-using-the-rails-command/ might be what you're after if that's your preferred approach.