<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.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>Moves On Rails: Tag puts</title>
    <link>http://www.movesonrails.com/articles/tag/puts?tag=puts</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>New ways to look at software</description>
    <item>
      <title>How to find all those stray y, puts and prints in your code</title>
      <description>&lt;p&gt;I have it all the time, I add some nasty console output to my ruby and some gets left behind. I wanted this to stop so I built a small regex to solve my problem.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;    {   name = 'console.output.ruby';
        match = '^\s*(y|puts|print|printf)[ ].*';
    },
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;If you add this to the ruby language def in Textmate and then update your style theme with a bright color (scope: console.output.ruby), those nasty buggers will really stand out.&lt;/p&gt;

&lt;p&gt;If you just want to get rid of them just run the regex above on your file (replace).&lt;/p&gt;</description>
      <pubDate>Tue, 28 Aug 2007 17:49:00 +0200</pubDate>
      <guid isPermaLink="false">urn:uuid:8da5108b-76ec-49d9-b33b-72939fcc902e</guid>
      <author>andre.foeken@movesonrails.com (Andre Foeken)</author>
      <link>http://www.movesonrails.com/articles/2007/08/28/how-to-find-all-those-stray-y-puts-and-prints-in-your-code</link>
      <category>Ruby</category>
      <category>regex</category>
      <category>y</category>
      <category>puts</category>
      <category>ruby</category>
      <category>grep</category>
      <category>textmate</category>
    </item>
  </channel>
</rss>
