In general gems are a more robust and supported way to add functionality to your app. There's a whole infrastructure on the Web and built into Rails to work with gems that isn't there for plugins.
For example, if you use a gem you get the whole set of Rake tasks for dealing with gems.
In your project root, run...
$ rake -T gem
(in /Users/username/project/someproject)
rake gems # List the gems that this rails application depends on
rake gems:build # Build any native extensions for unpacked gems
rake gems:build:force # Force the build of all gems
rake gems:install # Installs all required gems.
rake gems:refresh_specs # Regenerate gem specifications in correct format.
rake gems:unpack # Unpacks all required gems into vendor/gems.
rake gems:unpack:dependencies # Unpacks all required gems and their dependencies into vendor/gems.
rake rails:freeze:gems # Lock this application to the current gems (by unpacking them into vendor/rails)
You can also specify gem dependencies in your environment.rb
file. That gives you the ability to automatically install them with...
$ rake gems install
Another advantage of gems over plugins is that on the system level you have the gem
utility for maintaining gems so that makes things easier.
if it is as a gem ...when i put the
app on the clients server..will I not
have to get this plugin again?
You can "freeze" gems into your app and deploy them as part of the app without installing them on the system. If you do that you won't have to get the gem or the plugin again unless you want to upgrade it to a newer version.