<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="/stylesheets/rss.css" type="text/css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>Robby on Rails: Tag gems</title>
    <link>http://www.robbyonrails.com/articles/tag/gems</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>thoughts.sort_by{|t| t[:topic]}.collect </description>
    <item>
      <title>Managing Required Gems on Rails Projects</title>
      <description>&lt;p&gt;We&amp;#8217;re starting a new project and I&amp;#8217;m finding myself adding things to the code base that we&amp;#8217;ve done in the past&amp;#8230; hence the last few posts. As we&amp;#8217;re doing this, I&amp;#8217;d like to highlight some of the little things that we do on each project to maintain some consistency and in that process reach out to the community for alternative approaches.&lt;/p&gt;


	&lt;p&gt;I&amp;#8217;m intrigued by the &lt;a href="http://errtheblog.com/posts/50-vendor-everything"&gt;vendor everything&lt;/a&gt; concept, but we haven&amp;#8217;t yet adopted this on any of our projects (yet).&lt;/p&gt;


	&lt;p&gt;What we have been doing is to maintain a &lt;code&gt;REQUIRED_GEMS&lt;/code&gt; file in the root directory of our Rails application.&lt;/p&gt;


	&lt;p&gt;For example:&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
$ cat REQUIRED_GEMS

actionmailer
actionpack
actionwebservice
activerecord
activesupport
cgi_multipart_eof_fix
daemons
fastercsv
fastthread
feedtools
gem_plugin
image_science
mongrel
mongrel_cluster
mysql
rails
rake
RedCloth
Ruby-MemCache
soap4r
uuidtools
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Everybody on the team (designers/developers) knows to look here to make sure they have everything installed when beginning to work on the application.&lt;/p&gt;


	&lt;p&gt;This has worked fairly well from project to project but since we&amp;#8217;re starting a new project, I&amp;#8217;m curious if anybody has some better ways to approach this. Should we look more seriously at the vendor everything approach or are there any alternative approaches?&lt;/p&gt;
</description>
      <pubDate>Wed, 26 Mar 2008 22:27:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:1dad9e29-fb50-447c-802d-1a0f6109ff1d</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2008/03/26/managing-required-gems-on-rails-projects</link>
      <category>Ruby on Rails</category>
      <category>Ruby</category>
      <category>Programming</category>
      <category>PLANET ARGON</category>
      <category>gems</category>
      <category>rubyonrails</category>
      <category>ruby</category>
      <category>rails</category>
      <category>workflow</category>
      <category>team</category>
      <category>planetargon</category>
      <category>question</category>
      <category>tip</category>
    </item>
    <item>
      <title>Get to Know a Gem: Rak</title>
      <description>&lt;p&gt;A few months ago, I posted about an article that showed you &lt;a href="http://www.robbyonrails.com/articles/2007/10/06/spice-up-your-terminal-with-colored-grep-pattern-results"&gt;how to colorize your grep search results&lt;/a&gt;. Since then, I&amp;#8217;ve heard people talking about &lt;a href="http://petdance.com/ack/"&gt;ack&lt;/a&gt;, which describes itself as&amp;#8230;&lt;/p&gt;


	&lt;blockquote&gt;
		&lt;p&gt;&amp;#8220;a tool like grep, aimed at programmers with large trees of heterogeneous source code.&amp;#8221;&lt;/p&gt;
	&lt;/blockquote&gt;


	&lt;p&gt;It&amp;#8217;s written in Perl, which is fine and dandy&amp;#8230; but before I installed it, I heard that there was a Ruby version named &lt;a href="http://rak.rubyforge.org/"&gt;rak&lt;/a&gt;, which describes itself as&amp;#8230;&lt;/p&gt;


	&lt;blockquote&gt;
		&lt;p&gt;&amp;#8220;a grep replacement in pure Ruby. It accepts Ruby syntax regular expressions and automatically recurses directories, skipping .svn/, .cvs/, pkg/ and more things you don&amp;#8217;t care about. &amp;#8220;&lt;/p&gt;
	&lt;/blockquote&gt;


	&lt;p&gt;Sounds great. Let&amp;#8217;s see what this thing can do.&lt;/p&gt;


	&lt;h2&gt;Installing rak&lt;/h2&gt;


	&lt;p&gt;Daniel Lucraft, the author of rak, was kind enough to package it up as a Rubygem. So, all we have to do is install it via &lt;code&gt;gem install rak&lt;/code&gt;.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
   &amp;gt; sudo gem install rak                                                                                                                                                                                                     
  Password:
  Bulk updating Gem source index for: http://gems.rubyforge.org
  Successfully installed rak-0.8.0
  Installing ri documentation for rak-0.8.0...
  Installing RDoc documentation for rak-0.8.0...
  ~ &amp;gt;
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Great, let&amp;#8217;s move on.&lt;/p&gt;


	&lt;h2&gt;Using rak&lt;/h2&gt;


	&lt;p&gt;Now that it&amp;#8217;s installed, we can use Rak by typing &lt;code&gt;rak&lt;/code&gt; from the command line. You&amp;#8217;d typically want to run this from within the root of your application.&lt;/p&gt;


	&lt;p&gt;For example, basic usage would look like the following.&lt;/p&gt;


&lt;code&gt;$ rak search-pattern&lt;/code&gt;

	&lt;p&gt;In my first test, I ran &lt;code&gt;rak README&lt;/code&gt;.&lt;/p&gt;


	&lt;p&gt;&lt;img src="http://myskitch.com/robbyrussell/rak_output_1-20071211-083456.jpg" alt="" /&gt;&lt;/p&gt;


	&lt;p&gt;Immediately, I see a greater advantage to &lt;code&gt;rak&lt;/code&gt; over using &lt;code&gt;grep&lt;/code&gt; and that&amp;#8217;s because it&amp;#8217;s giving me line numbers for free, which takes remembering a few extra options with grep.&lt;/p&gt;


	&lt;p&gt;Like &lt;code&gt;grep&lt;/code&gt;, we can specify a specific path to search with. For example, we use a view helper named &lt;code&gt;link_to_unimplemented&lt;/code&gt; to help us track actions that aren&amp;#8217;t implemented yet. Looking at a current project, I can run &lt;code&gt;rak link_to_unimplemented app/views&lt;/code&gt; and produce the following results.&lt;/p&gt;


	&lt;p&gt;&lt;img src="http://myskitch.com/robbyrussell/terminal__less__160x49-20071211-085748.jpg" alt="" /&gt;&lt;/p&gt;


	&lt;p&gt;I&amp;#8217;m going to keep playing with it, but wanted to help get the word out. If you have any tips on using it, please share them in the comments. :-)&lt;/p&gt;
</description>
      <pubDate>Tue, 11 Dec 2007 11:10:00 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:ae4ad314-4ef2-4c9d-9388-152a1d7c956c</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2007/12/11/get-to-know-a-gem-rak</link>
      <category>Ruby</category>
      <category>Programming</category>
      <category>gems</category>
      <category>rubyforge</category>
      <category>rak</category>
      <category>grep</category>
      <category>terminal</category>
      <category>unix</category>
      <category>tip</category>
      <category>development</category>
      <category>code</category>
      <category>ruby</category>
    </item>
    <item>
      <title>Using MacPorts Ruby and Rails after Upgrading to OS X Leopard</title>
      <description>&lt;p&gt;If you previously followed my article, &lt;a href="http://www.robbyonrails.com/articles/2007/06/19/installing-ruby-on-rails-and-postgresql-on-os-x-second-edition"&gt;Installing Ruby on Rails and PostgreSQL on &lt;span class="caps"&gt;OS X&lt;/span&gt;, second edition&lt;/a&gt; and are now upgrading to &lt;span class="caps"&gt;OS X&lt;/span&gt; Leopard, you&amp;#8217;ll want to make a few adjustments to your setup.&lt;/p&gt;


	&lt;p&gt;First of all, it&amp;#8217;s great that Apple has decided to provide Ruby on Rails out of the box.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
~ &amp;gt; gem list rails                                                                                                                                                                   
  *** LOCAL GEMS ***

  rails (1.2.3)
      Web-application framework with template engine, control-flow layer,
      and ORM.
&lt;/code&gt;&lt;/pre&gt;

How many gems does it come with?
&lt;pre&gt;&lt;code&gt;
~ &amp;gt; gem list|grep '^[a-z]'|wc -l                                                                                                                                                     
      29
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;It&amp;#8217;s really great that &lt;a href="http://apple.com"&gt;Apple&lt;/a&gt; shipped Leopard pre-installed with 29 gems, especially if you don&amp;#8217;t have your entire Rails stack setup already. In my case and for those that have followed my installation process, you don&amp;#8217;t need to switch over to this new development stack (yet). I have a lot of time invested in my fully-functionaly MacPorts installation process (PostgreSQL, MySQL, RMagick, Subversion, Git, etc. Since this all working fine on my machine, I&amp;#8217;m not ready to make the switch to Apple&amp;#8217;s installation.&lt;/p&gt;


	&lt;h2&gt;Don&amp;#8217;t Fix it&amp;#8230; if it&amp;#8217;s not broken!&lt;/h2&gt;


	&lt;p&gt;So, the the first thing that I did was modify my &lt;code&gt;PATH&lt;/code&gt; environment variable, which has &lt;code&gt;/usr/bin&lt;/code&gt; as the first path that it&amp;#8217;ll look at when you try to run commands like &lt;code&gt;ruby&lt;/code&gt;, &lt;code&gt;mongrel_rails&lt;/code&gt;, &lt;code&gt;gem&lt;/code&gt;, etc. You&amp;#8217;ll want to modify this and prepend &lt;code&gt;/opt/local/bin:&lt;/code&gt; to the front of &lt;code&gt;PATH&lt;/code&gt; in your shell configuration. If you&amp;#8217;re using bash, this would be&amp;#8230; &lt;code&gt;~/.bashrc&lt;/code&gt;. If you&amp;#8217;re using zshell like me, &lt;code&gt;~/.zshrc&lt;/code&gt;.&lt;/p&gt;


	&lt;p&gt;Now, when you start a new Terminal and run &lt;code&gt;gem list&lt;/code&gt;, you&amp;#8217;ll see all of the gems that you already have installed.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
~ &amp;gt; gem list rails                                                                                                                                   &amp;lt; new-host

*** LOCAL GEMS ***

rails (1.2.5, 1.2.4, 1.2.3, 1.1.6)
    Web-application framework with template engine, control-flow layer,
    and ORM.
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Back to my happy gems&amp;#8230;&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
~ &amp;gt; gem list|grep '^[a-z]'|wc -l                                                                                                                                                              &amp;lt; new-host
      72
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Great! Now I can get back to work and spend time playing with the new features in Finder, Mail.app, and iChat instead of installing all of the software dependencies that our development projects have. :-)&lt;/p&gt;
</description>
      <pubDate>Sat, 27 Oct 2007 05:43:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:4c96e766-87e4-41f4-9d7d-54fe826ed4e9</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2007/10/27/using-macports-ruby-and-rails-after-upgrading-to-os-x-leopard</link>
      <category>RubyURL</category>
      <category>Ruby on Rails</category>
      <category>Ruby</category>
      <category>rails</category>
      <category>ruby</category>
      <category>gems</category>
      <category>rubyonrails</category>
      <category>osx</category>
      <category>DRY</category>
      <category>macports</category>
      <category>leopard</category>
      <category>zsh</category>
      <category>bash</category>
      <category>rmagick</category>
    </item>
    <item>
      <title>Gems Gone Wild!</title>
      <description>&lt;p&gt;&lt;a href="http://www.clarkware.com/cgi/blosxom/2007/02/10#GemSurvey"&gt;Mike Clark&lt;/a&gt; is offering everyone&lt;sup&gt;&lt;a href="#fn1"&gt;1&lt;/a&gt;&lt;/sup&gt; in the Ruby community &lt;a href="http://www.mardigras.com/"&gt;Mardis Gras&lt;/a&gt; beads&amp;#8230; in exchange for showing everyone your sexy gems. &lt;a href="http://chadfowler.com/2007/2/11/show-us-your-gems"&gt;Chad&lt;/a&gt; and &lt;a href="http://smartic.us/2007/2/11/show-us-your-gems"&gt;Bryan&lt;/a&gt; showed us theirs, so I figured it was my turn to show you all what I&amp;#8217;ve been hiding beneath this shell.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
    # gem list|grep '^[a-zA-Z]'
    actionmailer (1.2.5)
    actionpack (1.12.5)
    actionwebservice (1.1.6)
    activerecord (1.14.4)
    activesupport (1.3.1)
    asset_compiler (0.2)
    BlueCloth (1.0.0)
    builder (2.0.0)
    camping (1.5)
    capistrano (1.4.0, 1.3.1, 1.2.0)
    capistrano-ext (1.1.0)
    cgi_multipart_eof_fix (2.0.2)
    cheat (1.2.1)
    chronic (0.1.6)
    color (0.1.0)
    daemons (1.0.3, 0.4.4, 0.4.2)
    diff-lcs (1.1.2)
    facets (1.4.5)
    fastercsv (1.2.0)
    fastthread (0.6.2)
    feedtools (0.2.26)
    flexmock (0.5.0)
    gem_plugin (0.2.2, 0.2.1)
    gen (0.41.0)
    glue (0.41.0)
    google-geocode (1.2.1)
    gruff (0.2.8)
    hoe (1.1.6, 1.1.2)
    hpricot (0.5.110, 0.4.86, 0.4, 0.2)
    livejournal (0.3.1, 0.3.0)
    markaby (0.5)
    metaid (1.0)
    mocha (0.4.0)
    mongrel (1.0, 0.3.13.4, 0.3.13.3)
    mongrel_cluster (0.2.1, 0.2.0)
    needle (1.3.0)
    net-ping (1.2.0)
    net-sftp (1.1.0)
    net-ssh (1.0.10)
    nitro (0.41.0)
    og (0.41.0)
    payment (1.0.1)
    piston (1.2.1)
    postgres (0.7.1)
    quickbooks (0.0.2)
    rails (1.1.6)
    rake (0.7.1)
    rc-rest (2.1.0)
    rcov (0.7.0.1)
    RedCloth (3.0.4)
    rmagick (1.14.1)
    rspec (0.7.5, 0.7.4, 0.7.0, 0.6.4)
    ruby-breakpoint (0.5.0)
    ruby-growl (1.0.1)
    rubyforge (0.3.2, 0.3.1)
    RubyInline (3.6.2)
    shipping (1.5.0)
    sources (0.0.1)
    superredcloth (1.160)
    sydparse (1.2.0)
    syntax (1.0.0)
    tattle (1.0.1)
    unicode (0.1)
    uuidtools (1.0.0)
    xml-simple (1.0.10, 1.0.9)
    ZenTest (3.4.3, 3.4.1)
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Perhaps it is time to run some updates. Been running off of Rails edge forever and never remember to update those gems. :-)&lt;/p&gt;


	&lt;p&gt;&lt;strong&gt;puts his new beads on&amp;#8230;&lt;/strong&gt;&lt;/p&gt;


	&lt;p id="fn1"&gt;&lt;sup&gt;1&lt;/sup&gt; Okay, maybe I lied about the free beads&amp;#8230; ;-)&lt;/p&gt;
</description>
      <pubDate>Mon, 12 Feb 2007 01:27:00 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:cf680269-acb4-4fd2-a88b-df5f0c911c8a</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2007/02/12/gems-gone-wild</link>
      <category>Ruby</category>
      <category>Programming</category>
      <category>gems</category>
      <category>rubyforge</category>
    </item>
    <item>
      <title>The PLANET ARGON dot ORG project and asset compiling gone wild</title>
      <description>&lt;p&gt;&lt;a href="http://www.infoq.com/"&gt;InfoQ&lt;/a&gt; recently &lt;em&gt;unlaunched&lt;/em&gt; their new site that is dedicated to &lt;em&gt;&amp;#8220;tracking change and innovation in the enterprise software development community.&amp;#8221;&lt;/em&gt; One of the first articles published on the site was written by &lt;a href="http://www.jvoorhis.com"&gt;Jeremy Voorhis&lt;/a&gt;, Lead Architect at &lt;a href="http://www.planetargon.com"&gt;&lt;span class="caps"&gt;PLANET ARGON&lt;/span&gt;&lt;/a&gt;. Jeremys&amp;#8217; article, &lt;a href="http://www.infoq.com/articles/Agile-Asset-Management"&gt;Agile Asset Management with Ruby DSLs&lt;/a&gt; outlines an approach we took on a client project earlier this year for managing tons of assets for a Rails application. Our development team extracted this work and built &lt;code&gt;asset_compiler&lt;/code&gt;, which is now available as a gem on RubyForge and we&amp;#8217;ve recently setup a trac so you can post bugs, patches, and all things similar. We&amp;#8217;ll be announcing a few more open source plugins, gems, and projects in the near future as well. I know that many of you are wondering when and where &lt;code&gt;acts_as_legacy&lt;/code&gt; will show up&amp;#8230; keep your eye on the trac. ;-)&lt;/p&gt;


	&lt;p&gt;To install asset_compiler, run:&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;gem install asset_compiler&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Read the &lt;a href="http://asset-compiler.rubyforge.org/"&gt;asset compiler documentation&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;The &lt;a href="http://www.planetargon.org/"&gt;&lt;span class="caps"&gt;PLANET ARGON&lt;/span&gt; dot org project&lt;/a&gt;&lt;/p&gt;


	&lt;p&gt;Enjoy!&lt;/p&gt;
</description>
      <pubDate>Fri, 26 May 2006 09:17:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:2dd869ad-078b-48cf-9099-f0ae6e38ed33</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2006/05/26/the-planet-argon-dot-org-project-and-asset-compiling-gone-wild</link>
      <category>planetargon</category>
      <category>jvoorhis</category>
      <category>infoq</category>
      <category>ruby</category>
      <category>rake</category>
      <category>gems</category>
    </item>
    <item>
      <title>RubyGems mirror to kill the wait</title>
      <description>&lt;p&gt;Like &lt;a href="http://piece.dpiddy.net/articles/2005/10/18/need-more-power-and-speed"&gt;Dan Peterson&lt;/a&gt;, I have setup a mirror of the RubyGems repository on the same server that is an official RubyForge mirror.&lt;/p&gt;


	&lt;p&gt;&lt;a href="http://rubyforge.planetargon.com/gems.rubyforge.org"&gt;http://rubyforge.planetargon.com/gems.rubyforge.org&lt;/a&gt;&lt;/p&gt;


&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_ruby "&gt;
&lt;span class="ident"&gt;gem&lt;/span&gt; &lt;span class="ident"&gt;install&lt;/span&gt; &lt;span class="punct"&gt;--&lt;/span&gt;&lt;span class="ident"&gt;source&lt;/span&gt; &lt;span class="ident"&gt;http&lt;/span&gt;&lt;span class="punct"&gt;:/&lt;/span&gt;&lt;span class="regex"&gt;&lt;/span&gt;&lt;span class="punct"&gt;/&lt;/span&gt;&lt;span class="ident"&gt;rubyforge&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;planetargon&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;com&lt;/span&gt;&lt;span class="punct"&gt;/&lt;/span&gt;&lt;span class="ident"&gt;gems&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;rubyforge&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;org&lt;/span&gt; &lt;span class="ident"&gt;postgres&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

	&lt;p&gt;The RubyForge mirror team is working on a gem mirroring solution&amp;#8230; and in the meantime, this is my attempt to help out with the load.&lt;/p&gt;


	&lt;p&gt;Dan also noted that you could modify the &lt;code&gt;.gemrc&lt;/code&gt; file:&lt;/p&gt;


&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_ruby "&gt;&lt;span class="ident"&gt;gem&lt;/span&gt;&lt;span class="punct"&gt;:&lt;/span&gt; &lt;span class="punct"&gt;--&lt;/span&gt;&lt;span class="ident"&gt;source&lt;/span&gt; &lt;span class="ident"&gt;http&lt;/span&gt;&lt;span class="punct"&gt;:/&lt;/span&gt;&lt;span class="regex"&gt;&lt;/span&gt;&lt;span class="punct"&gt;/&lt;/span&gt;&lt;span class="ident"&gt;rubyforge&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;planetargon&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;com&lt;/span&gt;&lt;span class="punct"&gt;/&lt;/span&gt;&lt;span class="ident"&gt;gems&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;rubyforge&lt;/span&gt;&lt;span class="punct"&gt;.&lt;/span&gt;&lt;span class="ident"&gt;org&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

	&lt;p&gt;Thanks Danp for pointing this out&amp;#8230; and Enjoy!&lt;/p&gt;
</description>
      <pubDate>Tue, 18 Oct 2005 23:38:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:5265a3e19fbe53bef54613cd1af9ae8b</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2005/10/18/rubygems-mirror-to-kill-the-wait</link>
      <category>Ruby</category>
      <category>gems</category>
      <category>ruby</category>
    </item>
  </channel>
</rss>
