a gem into plugin folder

hi guys

i am working ona ubuntu hardy heron box. just wanted to know is there a command to install(copy) a gem in my system as a plugin into my rails project

or it has to be done manually by locating gems directory inside my ruby installation folder.

also wanted to know whether there would be any issues bcos of using a gem as a plugin or is it perctecly ok to do it.

jags

Hi Jags,

Jags Rao wrote:

also wanted to know whether there would be any issues bcos of using a gem as a plugin or is it perctecly ok to do it.

I think the answer to your question is probably yes, using a gem as a plugin would probably cause issues. Gems and Plugins have separate purposes. Gems extend Ruby. Plugins extend Rails. They're put in separate places because Ruby and Rails search for extensions in different places.

Aside from that... what is it you're trying to accomplish? If you already have the functionality you're looking for as a gem, why would you want to move that to a plugin?

Best regards, Bill

This link doesn't tell you had to install a gem as a plugin per se but it does tell you how to put your gems into your vendors directory.

This link doesn't tell you had to install a gem as a plugin per se but it does tell you how to put your gems into your vendors directory.

Vendor Everything — err.the_blog

If you're on rails 2.1 you'll want to look at the new gem dependency
stuff, it will do all the gem vendoring stuff for you

Fred

hello all

first thx for all the replies

hi bill i was actually looking for this when i came across the haml plugin. initially it was available as plugin and also as gem and i used it as plugin but now it has to be installed as gem and then we do a command which copies a file to the plugin folder(dont know what we call doing this technically).

then i learnt that i can copy the gem to vendor/plugins and it wud work the same so was looking for command

i am on rails 2.1.0 and it seems the rake gems:unpack is the command i'm looking for but there seems to be some rough edges with gem dependency things in rails 2.1.0. as per the comments on this article by ryandaigle

http://ryandaigle.com/articles/2008/4/1/what-s-new-in-edge-rails-gem-dependencies

so for now i am locating the haml gem in my ruby installation i.e

/usr/lib/ruby/gems/1.8/gems/haml-2.0.1/ and copying it to my plugins folder

again thanks for responses...