Skip to main content

Freezing Gems

What is a gem and why would you want to freeze it?

In Ruby, there are times when you want to access pieces of functionality that other people of written (3rd party libraries) and you normally have 2 options. You can install a plug in or install a gem. Normally the method you use is determined by which ever is made available by the author.

Gems are installed on the host machine and are pretty handy when you want to run things in the command line or else across lots of projects, but their downside is that if you use a gem in a Rails project there is no automatic publishing mechanism when you deploy your site. You will need to log onto the remote host machine and install the gem manually.

Plugins are specific to Rails and are similar to gems in that they are also 3rd party libraries. However they are associated with your Rails project as opposed to your machine so they will get posted to the server on a regular deploy.

Freezing a gem is the process of transforming a gem into a plug in. Essentially the gem is "unwrapped" and installed into your Rails plug ins directory.
  1. Make sure the gem you want to freeze is installed.
  2. Navigate to your Rails project's home directory and type the following
  3. script/plugin install
    (this is the plugin which will freeze the gem)
  4. rake gems:freeze GEM=gem_name
Note that not every gem can be frozen successfully. Some gems rely on executables which are platform specific and these cannot be accessed from the plugins directory.


Anonymous said… global and other list ashley furniture [url=]ashley furniture[/url], calqsrh, allegiant air [url=]allegiant air[/url], odkrhto, pressure washers [url=]pressure washers[/url], 00579, dishnetwork [url=]dishnetwork[/url], wphtyf, adt security [url=]adt security[/url], dqqad,
Anonymous said… Hello good day [url=""]lexapro[/url] tels chuyen [url=""]synthroid side effects[/url] guevara blanchard [url=""]avodart[/url] smoking [url=""]allegra[/url] concise [url=""]inderal side effects[/url] biogene
Anonymous said…
werb nxuuf Free Porn crhzrp v yk z fit
Anonymous said…
I agree with the post above and I will find more information from google.
Anonymous said…
uoow sllvk free sex szdpzbv g zm s aaw
There are may person searching about that now they will find enough resources by your post,
ファロム said…
Hi there,
Really nice job,There are many people searching about that now they will find enough sources by your tips.
Also looking forward for more tips about that
Wow, Great post,Nice work, I would like to read your blog every day Thanks
Això és realment interessant, ets un blogger molt hàbil. M'he unit a la seva alimentació i esperem que busquen més del seu missatge meravellós. A més, he compartit el seu lloc en els meus xarxes socials !
Gems are as similar as the plugins.I used one some days ago and they are really handy.
Austin Mortgage said…
I just wanted to thank you again, amazing site, where you have developed. It is for those who are actually interested in this particular topic, especially this post useful skills. Do you really all so sweet and considerate with others, plus read your blog post is a fantastic joy
jugan said…
This is so cool. I am such a huge fan of their work. I really am impressed with how much you have worked to make this website so enjoyable.
wound care
Never heared about this technique freezing gems. Looks amazing. Let me try it also.
I feel delighted to read such a good post. The author has done a great job in sharing this great piece of news with us through this blog. Thanks. Keep up the good work.
Dissertation said…
Thanks for this I have been searching for freezing gems information dissertation help
Dissertation said…
That is great! love to read about gems. Great shared. Thanks alot essay help.
I really like your writing. Thanks so much, finally a decent website with good information in it.
I'm impressed. You're truly well informed and very intelligent. You wrote something that people could understand and made the subject intriguing for everyone. I'm saving this for future use.
foley catheter said…
I really don't have words to describe how much I liked this article of yours. The author really know his job well. Thanks for this wonderful share.
aquacel said…
Fantastic post indeed. Thanks to the author for this great share. Looking forward for more quality stuff. Thanks again.
hanumant said…
I actually enjoyed reading through this posting.Many thanks.

Dissertations Help
no matter what the pros and cons of installing gems. I love to install gems on my machines

Popular posts from this blog

Master of my domain

Hi All, I just got myself a new domain ( ). The reason is that is offering cheap domain via and I thought after having this nickname for nigh on 10 years it was time to buy the domain before someone else did (also I read somewhere that using in your domain is the equivalent of an or email address...shudder...). Of course I forgot that I would have to re-register my blog everywhere (which is taking ages) not to mention set up all my stats stuff again. *sigh*. It's a blogger's life... In any case, don't forget to bookmark the new address and to vote me up on Technorati !

Speeding up RSpec

So today I have been looking into getting our enormous battery of tests to run faster. I have yet to find anything that works for Cucumber, but I did find an interesting way to speed up RSpec which is detailed here. Basically, it seems that by not collecting garbage too frequently, you can make your tests run much faster (at the expense of memory management of course). We observed a 30% reduction in the time it takes to run an RSpec test suite. I did try to implement this on Cucumber, however because we need to store much more in memory to set up and tear down our objects, it meant that I kept running out of memory when I wasn't using the default Garbage Collection and the tests took even longer (so, buyer beware). I suppose if you had a small set of features though you might see some benefit.

Responsive Web Design

I wanted to go over Responsive Web Design using CSS. In the old days of web development, we had to code to common screen sizes (i.e. 800 X 600, 1024 X 768) and we patiently waited for people to upgrade their computers to have a decent amount of screen real estate so we could design things the way we really wanted. We also took on semi stretchy web layouts etc to expand and contract appropriately. Then about 2 or 3 years ago, Apple released this little device called an iPhone with a 320 X 480 resolution which took the world by storm and suddenly a lot of people were viewing your website on a tiny screen again... Anyways, as it can be difficult to design a site which looks good on 320 X 480 AND 1680 X 1050, we need to come up with some kind of solution. One way is to sniff the client and then use an appropriate stylesheet, but then you are mixing CSS with either JavaScript or server side programming and also potentially maintaining a list of appropriate clients and stylesheets. Also, you