# Gem and pluggin

**URL:** <https://www.ruby-forum.com/t/gem-and-pluggin/138122>\
**Category:** Rails\
**Created:** [May 20, 2008, 11:59am UTC](https://www.ruby-forum.com/t/gem-and-pluggin/138122 "2008-05-20T11:59:40Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [May 20, 2008, 11:59am UTC](https://www.ruby-forum.com/t/gem-and-pluggin/138122/1 "2008-05-20T11:59:40Z")

</div>

Hi  
This is a general question.What is the differnece between these  
?Why I am asking such a question is i am using will\_paginate  
pluggin…Now it is available as gem…So is there any performance  
(stability and speed of execution) difference?

Thanks in advance  
Sijo

---

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [May 20, 2008, 12:04pm UTC](https://www.ruby-forum.com/t/gem-and-pluggin/138122/2 "2008-05-20T12:04:07Z")

</div>

On 20 May 2008, at 10:59, Sijo Kg wrote:

> Hi  
> This is a general question.What is the differnece between these  
> ?Why I am asking such a question is i am using will\_paginate  
> pluggin…Now it is available as gem…So is there any performance  
> (stability and speed of execution) difference?

plugins are rails specific, gems are a general ruby way of  
distributing code. gems have the advantage of already having a lot of  
stuff in place for dependencies versionning etc…  
rails does some special things to plugins, eg loading them at a well  
defined point in the boot process, evaling init.rb etc… (rails 2.1  
will load plugins from gems too).

Fred

---

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [May 20, 2008, 3:57pm UTC](https://www.ruby-forum.com/t/gem-and-pluggin/138122/3 "2008-05-20T15:57:12Z")

</div>

My problem is that I waffle back -n- forth over what is best.  
Sometimes I think gems because they are the ruby way, and are so well  
supported (as Fred said). Othertimes I think: plugins so I can have  
all the project code in the project. But then the projects get huge.  
And sometimes updating a plugin isn’t as straightforward. And the  
plugin management keeps change (used to by SVN, now it’s all GIT…  
what’s next?).

So I dunno. I like that with a plugin you don’t have to add any code  
(no “require” line), but then again, it’s only one line.

Hmmm… conundrum

-Danimal

On May 20, 4:03 am, Frederick C. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)

---

<div class="post-metadata">

**Author:** ![sijo](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/da6949/32.png) [@sijo](https://www.ruby-forum.com/u/sijo)\
**Post date:** [May 21, 2008, 6:06am UTC](https://www.ruby-forum.com/t/gem-and-pluggin/138122/4 "2008-05-21T06:06:36Z")

</div>

Hi  
Thanks for the reply  
Sijo
