<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Codeulate. &#187; general</title>
	<atom:link href="http://codeulate.com/category/general/feed/" rel="self" type="application/rss+xml" />
	<link>http://codeulate.com</link>
	<description></description>
	<lastBuildDate>Mon, 03 Oct 2011 04:12:10 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.3</generator>
		<item>
		<title>Just closed more funding? My condolences.</title>
		<link>http://codeulate.com/2011/10/my-condolences/</link>
		<comments>http://codeulate.com/2011/10/my-condolences/#comments</comments>
		<pubDate>Mon, 03 Oct 2011 04:12:10 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=393</guid>
		<description><![CDATA[When a popular company announces a new round of funding, the Hacker News comment threads are usually overwhelmingly congratulatory. This attitude is horribly misguided. In my eyes, announcing post-seed funding is a BAD thing, and should be close to a PR disaster. The HN threads should be full of condolences. Here&#8217;s why. The company hasn&#8217;t [...]]]></description>
			<content:encoded><![CDATA[<p>When a popular company announces a new round of funding, the Hacker News comment threads are usually overwhelmingly congratulatory. This attitude is horribly misguided. In my eyes, announcing post-seed funding is a BAD thing, and should be close to a PR disaster. The HN threads should be full of condolences. Here&#8217;s why.</p>
<h2>The company hasn&#8217;t figured out how to pay its bills</h2>
<p>At the end of the day, a company exists to make money. Every round of funding (past, maybe, a seed round) is an admission that you still haven&#8217;t figured out a business model that will keep the damn lights on. Every startup should want each round of funding to be its last.</p>
<h2>The founders have ceded control</h2>
<p>Companies in very strong positions are sometimes able to take funding without losing much control of the company, but this is rare. In general, founders are turning over substantial control to professional gamblers with horrible succes rates. A VC will never love your company like you do; he&#8217;s there only to get paid. This will forever taint your relationship.</p>
<h2>Part of the company was sold prematurely</h2>
<p>People seem to forget that &#8220;getting funded&#8221; really means &#8220;selling part of the store&#8221;. If you think your company is going to be worth more in the future, why are you selling part of it now?</p>
<p>Here&#8217;s an announcement I&#8217;d love to congratulate: <em>&#8220;we&#8217;ve recently reached profitability and know we can keep the lights on. We think we can make even more money in the future, so we&#8217;re going to hang on to as much precious equity as we can. Offers for outside funding are flattering but unnecessary.&#8221;</em></p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/10/my-condolences/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Let&#8217;s read some Rails code: with_options</title>
		<link>http://codeulate.com/2011/06/dry-up-your-rails-code-with_options/</link>
		<comments>http://codeulate.com/2011/06/dry-up-your-rails-code-with_options/#comments</comments>
		<pubDate>Sun, 05 Jun 2011 07:35:41 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=358</guid>
		<description><![CDATA[Did you know you can refactor this: # Duplicated :dependent =&#62; :destroy option. class Account &#60; ActiveRecord::Base &#160; has_many :customers, :dependent =&#62; :destroy &#160; has_many :products, &#160;:dependent =&#62; :destroy &#160; has_many :invoices, &#160;:dependent =&#62; :destroy &#160; has_many :expenses, &#160;:dependent =&#62; :destroy end into this? # Nice and DRY! class Account &#60; ActiveRecord::Base &#160; with_options :dependent [...]]]></description>
			<content:encoded><![CDATA[<p>Did you know you can refactor this:</p>
<div class="codecolorer-container ruby vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:635px;"><div class="ruby codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color:#008000; font-style:italic;"># Duplicated :dependent =&gt; :destroy option.</span><br />
<span style="color:#9966CC; font-weight:bold;">class</span> Account <span style="color:#006600; font-weight:bold;">&lt;</span> <span style="color:#6666ff; font-weight:bold;">ActiveRecord::Base</span><br />
&nbsp; has_many <span style="color:#ff3333; font-weight:bold;">:customers</span>, <span style="color:#ff3333; font-weight:bold;">:dependent</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:destroy</span><br />
&nbsp; has_many <span style="color:#ff3333; font-weight:bold;">:products</span>, &nbsp;<span style="color:#ff3333; font-weight:bold;">:dependent</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:destroy</span><br />
&nbsp; has_many <span style="color:#ff3333; font-weight:bold;">:invoices</span>, &nbsp;<span style="color:#ff3333; font-weight:bold;">:dependent</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:destroy</span><br />
&nbsp; has_many <span style="color:#ff3333; font-weight:bold;">:expenses</span>, &nbsp;<span style="color:#ff3333; font-weight:bold;">:dependent</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:destroy</span><br />
<span style="color:#9966CC; font-weight:bold;">end</span></div></div>
<p>into this?</p>
<div class="codecolorer-container ruby vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:635px;"><div class="ruby codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color:#008000; font-style:italic;"># Nice and DRY!</span><br />
<span style="color:#9966CC; font-weight:bold;">class</span> Account <span style="color:#006600; font-weight:bold;">&lt;</span> <span style="color:#6666ff; font-weight:bold;">ActiveRecord::Base</span><br />
&nbsp; with_options <span style="color:#ff3333; font-weight:bold;">:dependent</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:destroy</span> <span style="color:#9966CC; font-weight:bold;">do</span> <span style="color:#006600; font-weight:bold;">|</span>assoc<span style="color:#006600; font-weight:bold;">|</span><br />
&nbsp; &nbsp; assoc.<span style="color:#9900CC;">has_many</span> <span style="color:#ff3333; font-weight:bold;">:customers</span><br />
&nbsp; &nbsp; assoc.<span style="color:#9900CC;">has_many</span> <span style="color:#ff3333; font-weight:bold;">:products</span><br />
&nbsp; &nbsp; assoc.<span style="color:#9900CC;">has_many</span> <span style="color:#ff3333; font-weight:bold;">:invoices</span><br />
&nbsp; &nbsp; assoc.<span style="color:#9900CC;">has_many</span> <span style="color:#ff3333; font-weight:bold;">:expenses</span><br />
&nbsp; <span style="color:#9966CC; font-weight:bold;">end</span><br />
<span style="color:#9966CC; font-weight:bold;">end</span></div></div>
<p>The with_options method is a really cool chunk of code that lets you DRY up duplication that sometimes appear when passing the same options to a series of methods.</p>
<p>But the point of this post is <strong>how it works behind the scenes</strong>, so check out this 11-minute code walkthrough:</p>
<p><iframe width="640" height="375" src="http://www.youtube.com/embed/OBOl9fFuILk?hd=1"  allowfullscreen></iframe></p>
<p>By the way, this is an excerpt of a longer screencast I&#8217;m working on about ActiveSupport internals. If you&#8217;d like to be notified when the full screencast is released, <a href="http://codeulatescreencasts.wufoo.com/forms/want-an-email-when-the-screencast-is-released/">drop your email in this form</a>. (One email, ever.)</p>
<p>You can also <a href="http://www.codeulatescreencasts.com">check out the other Rails-related screencasts I&#8217;ve already done</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/06/dry-up-your-rails-code-with_options/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Video: write code faster &#8212; expert-level vim</title>
		<link>http://codeulate.com/2011/05/video-write-code-faster-expert-level-vim/</link>
		<comments>http://codeulate.com/2011/05/video-write-code-faster-expert-level-vim/#comments</comments>
		<pubDate>Mon, 30 May 2011 23:40:12 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=355</guid>
		<description><![CDATA[In May of 2010 I gave a one-hour talk to the Boston Ruby Group titled &#8216;Write Code Faster: Expert-level Vim&#8217;. I&#8217;d volunteered to give it as a test-run before delivering the same talk at RailsConf a month later. Little did I know, someone recorded the Boston.rb talk and it recently surfaced on the presentations page. [...]]]></description>
			<content:encoded><![CDATA[<p>In May of 2010 I gave a one-hour talk to the Boston Ruby Group titled &#8216;Write Code Faster: Expert-level Vim&#8217;.</p>
<p>I&#8217;d volunteered to give it as a test-run before delivering the same talk at RailsConf a month later.</p>
<p>Little did I know, someone recorded the Boston.rb talk and it recently surfaced on <a href="http://bostonrb.org/presentations">the presentations page</a>.</p>
<p>If the title sounds interesting, <a href="http://bostonrb.org/presentations/25">go watch the talk!</a></p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/05/video-write-code-faster-expert-level-vim/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Let&#8217;s read some Rails code: OrderedOptions</title>
		<link>http://codeulate.com/2011/05/lets-read-some-rails-code-orderedoptions/</link>
		<comments>http://codeulate.com/2011/05/lets-read-some-rails-code-orderedoptions/#comments</comments>
		<pubDate>Sat, 28 May 2011 23:55:12 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=345</guid>
		<description><![CDATA[Curious about Rails&#8217; internals? In the screencast below, I take you on a 5-minute tour of the OrderedOptions and InheritedOptions classes in ActiveSupport. Check it out for a code-level tour of an interesting bit of Rails. By the way, this is an excerpt of a longer screencast I&#8217;m creating of guided tour through the best [...]]]></description>
			<content:encoded><![CDATA[<p>Curious about Rails&#8217; internals? In the screencast below, I take you on a 5-minute tour of the OrderedOptions and InheritedOptions classes in ActiveSupport. Check it out for a code-level tour of an interesting bit of Rails.</p>
<p>By the way, this is an excerpt of a longer screencast I&#8217;m creating of guided tour through the best parts of the Rails source. If you&#8217;d like to be notified when the full screencast is released, <a href="http://codeulatescreencasts.wufoo.com/forms/want-an-email-when-the-screencast-is-released/">drop your email in this form</a>. (One email, ever.)</p>
<p><iframe width="640" height="349" src="http://www.youtube.com/embed/PVkJR2wBEBM" frameborder="0" allowfullscreen></iframe></p>
<p>UPDATE: Youtube&#8217;s compression isn&#8217;t looking so hot, so if you prefer, you can <a href="http://downloads.codeulatescreencasts.com/ordered_options.mov">download the high quality version here</a>. (43MB)</p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/05/lets-read-some-rails-code-orderedoptions/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
<enclosure url="http://downloads.codeulatescreencasts.com/ordered_options.mov" length="45555357" type="video/quicktime" />
		</item>
		<item>
		<title>2011 Boston Rails Developer Salary Survey</title>
		<link>http://codeulate.com/2011/04/2011-boston-rails-developer-salary-survey/</link>
		<comments>http://codeulate.com/2011/04/2011-boston-rails-developer-salary-survey/#comments</comments>
		<pubDate>Fri, 29 Apr 2011 19:28:32 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=329</guid>
		<description><![CDATA[Summary: an anonymous survey with 50 responses indicates that the average salary for full-time, Boston-based Rails developers is $99,646 Several weeks ago I posted to the Boston Ruby Group mailing list asking people how much money they made. I asked people for their annual salary (including bonuses), how they&#8217;d rate their Rails skills from 1-10, [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Summary: an anonymous survey with 50 responses indicates that the average salary for full-time, Boston-based Rails developers is $99,646</strong></p>
<p>Several weeks ago I posted to the Boston Ruby Group mailing list asking people how much money they made. I asked people for their annual salary (including bonuses), how they&#8217;d rate their Rails skills from 1-10, whether they managed other developers, and whether they were freelancers.</p>
<p><a href="http://codeulatescreencasts.wufoo.com/forms/2011-boston-rails-salary-survey/">See the original survey</a>. </p>
<p><strong>Results:</strong><br />
Average salary (non-freelancers): $99,646</p>
<p>Average salary (freelancers): $114,000</p>
<p>Average salary (no management of other devs): $88,340</p>
<p>Average salary (with management of other devs): $113,040</p>
<p>Average self-rating of Rails ability (1-10): 7</p>
<p>Raw data, and the brutally-complicated code I wrote for averaging a handful of numbers <a href="https://github.com/r00k/salary_survey_2011">lives on github</a>.</p>
<p><strong>Thoughts on the results:</strong><br />
Based on conversations with those familiar with the local market and my own experience, these numbers seem a bit high. I have a hunch there is selection bias at work: perhaps developers that are proud of their salaries are more likely to respond. Additionally, I&#8217;d guess there&#8217;s a tendency for people to exaggerate slightly on these sorts of surveys. Naturally, you should treat these numbers as you would any drawn from an anonymous survey sent to a public mailing list.</p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/04/2011-boston-rails-developer-salary-survey/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Bundler&#8217;s got bash-fu</title>
		<link>http://codeulate.com/2011/03/bundlers-got-bash-fu/</link>
		<comments>http://codeulate.com/2011/03/bundlers-got-bash-fu/#comments</comments>
		<pubDate>Wed, 16 Mar 2011 04:13:34 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=315</guid>
		<description><![CDATA[Well, technically got it&#8217;s got POSIX-compliant-fu. But that&#8217;s even better; so no worries. Check out this line from bundler&#8217;s gemspec. The goal of this line is to set s.test_files to an array of file located in testing-related directories: s.test_files = `git ls-files -- {test,spec,features}/*`.split&#40;&#34;\n&#34;&#41; There are a couple interesting things going on in this line: [...]]]></description>
			<content:encoded><![CDATA[<p>Well, technically got it&#8217;s got POSIX-compliant-fu. But that&#8217;s even better; so no worries.</p>
<p>Check out this line from bundler&#8217;s <a href="https://github.com/carlhuda/bundler/blob/1-0-stable/bundler.gemspec">gemspec</a>. The goal of this line is to set s.test_files to an array of file located in testing-related directories:</p>
<div class="codecolorer-container ruby vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:635px;"><div class="ruby codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">s.<span style="color:#9900CC;">test_files</span> = <span style="color:#996600;">`git ls-files -- {test,spec,features}/*`</span>.<span style="color:#CC0066; font-weight:bold;">split</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#996600;">&quot;<span style="color:#000099;">\n</span>&quot;</span><span style="color:#006600; font-weight:bold;">&#41;</span></div></div>
<p>There are a couple interesting things going on in this line:</p>
<ul>
<li><strong>git ls-files</strong>: by default, this command outputs all the files in the index, but we&#8217;re going to constrain it with a path supplied by&#8230;</li>
<li><strong>{test,spec,features}</strong>: this is a &#8220;curly brace expansion&#8221;. In bash (and other POSIX shells), this will expand to &#8220;test spec features&#8221;, however notice that we&#8217;ve got a trailing&#8230;</li>
<li><strong>/*</strong>: when you&#8217;ve got leading or trailing characters around expansions, they are included in the expansion. So the full command of {test,spec,features}/* expands to &#8220;test/* spec/* features/*&#8221;</li>
<li>Finally, git ls-files outputs the names of all the files in those directories, and we split them on newlines to get our array.
</ul>
<p>Finally, if you like the idea of curly brace expansions, but prefer to stay in Ruby-land, you can have the best of both worlds:</p>
<div class="codecolorer-container ruby vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:635px;"><div class="ruby codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color:#CC00FF; font-weight:bold;">Dir</span>.<span style="color:#9900CC;">glob</span><span style="color:#006600; font-weight:bold;">&#40;</span><span style="color:#996600;">&quot;{test,spec,features}/*&quot;</span><span style="color:#006600; font-weight:bold;">&#41;</span> <span style="color:#008000; font-style:italic;"># This also works</span></div></div>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/03/bundlers-got-bash-fu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to Recruit Me</title>
		<link>http://codeulate.com/2011/02/how-to-recruit-me/</link>
		<comments>http://codeulate.com/2011/02/how-to-recruit-me/#comments</comments>
		<pubDate>Thu, 10 Feb 2011 00:35:58 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=252</guid>
		<description><![CDATA[I get emails from two to four recruiters per month. Sadly, most of their emails look like the following, received today: Ben, I am the lead technical recruiter at (Company Name). We are a social media technology company sitting atop the social media marketing revolution and are looking to grow our talented team. I came [...]]]></description>
			<content:encoded><![CDATA[<p>I get emails from two to four recruiters per month. Sadly, most of their emails look like the following, received today:</p>
<blockquote><p>
Ben,</p>
<p>I am the lead technical recruiter at (Company Name). We are a social media technology company sitting atop the social media marketing revolution and are looking to grow our talented team.  I came across your profile while doing some outreach. I was impressed by what I saw on your profile and your community contributions and would be very interested in speaking with you about our need for strong Ruby Developers and your career goals. There is no pressure if you are not in the market.  I am more than happy to answer any questions that you might have as well.</p>
<p>I encourage you to look at our website (link) to check out our job postings, read about our story, and check out our awards!</p>
<p>Let me know a good time to connect.  I look forward to speaking with you.</p>
<p>Thanks,</p>
<p>Kelly (Last Name)
</p></blockquote>
<p>This email sucks for several reasons, but by far its worst offense is that it&#8217;s not about ME. There&#8217;s nothing in here that indicates Kelly wants to hire ME, she just wants to hire SOMEONE: another notch in her bedpost. This does not give me the warm fuzzy feeling.</p>
<p>I have never responded to an email of this nature.</p>
<p>As a means of dramatic contrast, let&#8217;s look at an email from a different recruiter that&#8217;s so damn good it makes me giddy:</p>
<blockquote><p>
Hi Ben,</p>
<p>I hope you&#8217;re well.  I&#8217;m rather certain that you know about Airbnb as you had replied to a thread on Hacker News that I had posted on our need for Rails engineers a couple of months back &#8211; (link).  We&#8217;ve since added three engineers to the team, remaining selective and adding a couple of front-end talents to our crew.</p>
<p>I was wondering what your current situation is as I had noticed on your Codeulate About page and workingwithrails.com profile stated that you&#8217;re available.  I&#8217;m interested in having a chat with you about what we&#8217;re doing here and whether you would be interested in joining us full time.</p>
<p>Another factor that you might be interested in knowing is that despite being based in Boston, if we thought we would be a great fit for each other, Airbnb would be more than happy in assist in relocating you to San Francisco.</p>
<p>Let me know what your thoughts are!<br />
Barry
</p></blockquote>
<p>I didn&#8217;t anonymize this one because Barry and Airbnb deserve massive kudos&#8211;this is the best damn recruitment email I&#8217;ve ever received.</p>
<p>Barry has read my comments on Hacker News, found my profile on workingwithrails.com, read my blog, and knows where I live. I am physically incapable of disliking someone who strokes my ego so thoroughly. How can you be disinterested in someone so interested in you? Barry&#8217;s telling me that he&#8217;s done his research, liked what he saw, and thinks I&#8217;d be a good addition to his team. That is a damn good start with one email&#8211;if I were interested in moving out to SF, I&#8217;d be all over that.</p>
<p>I&#8217;d love to see more recruiters copying Barry&#8217;s approach. You&#8217;ll get better results and I&#8217;ll get less spam. I love when everybody wins.</p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/02/how-to-recruit-me/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to land your first patch in Rails</title>
		<link>http://codeulate.com/2011/02/how-to-land-your-first-patch-in-rails/</link>
		<comments>http://codeulate.com/2011/02/how-to-land-your-first-patch-in-rails/#comments</comments>
		<pubDate>Tue, 08 Feb 2011 06:13:39 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>
		<category><![CDATA[rails]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=241</guid>
		<description><![CDATA[If you&#8217;re looking for a way to contribute back to Rails, the quickest way to get your first patch in is by improving its documentation. Some people don&#8217;t find patching documentation as sexy as slinging code, but I&#8217;ve come to love the humble doc patch. Here&#8217;s why they&#8217;re so great: It&#8217;s easy to get started. [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re looking for a way to contribute back to Rails, the quickest way to get your first patch in is by <strong>improving its documentation</strong>.</p>
<p>Some people don&#8217;t find patching documentation as sexy as slinging code, but I&#8217;ve come to love the humble doc patch. Here&#8217;s <strong>why they&#8217;re so great</strong>:</p>
<p><strong>It&#8217;s easy to get started</strong>. Your first patch can be as simple as fixing a typo in a <a href="http://guides.rubyonrails.org/">Rails Guide</a>. Later, when you&#8217;re feeling more at ease with the process, you can improve the documentation for a class or method right in the code. Find an undocumented class, dig into its guts, and write a good summary. Ever read the examples for a method and think they could be improved? Don&#8217;t grimace and move on; fix it!</p>
<p><strong>Your patch will be merged in quickly</strong>. All patches to Rails&#8217; documentation go into the <a href="https://github.com/lifo/docrails">docrails</a> repository. This repo has an OPEN COMMIT POLICY: you simply message lifo on github and he&#8217;ll give you commit rights. You can make your patches at will, and the repo is regularly merged with the official Rails repository (<a href="https://github.com/rails/rails/commit/8b5dc9caa52a2877e3ecc207515fd156abad45e0">here&#8217;s the most recent example</a> of that happening). There&#8217;s no lengthy signoff process, so your commits will never languish while waiting for &#8220;+1s&#8221; or attention from a core member.</p>
<p><strong>Most people don&#8217;t want to do it. </strong>It&#8217;s actually pretty tough to find bugs in Rails to fix. There are so many Rubyists crawling all over it that there&#8217;s just not that much low-hanging fruit to patch. However, most developers don&#8217;t really like writing prose, so there&#8217;s a lot of easily-improved or outright missing documentation out there.</p>
<p><strong>Your commits count toward the Rails contributors <a href="http://contributors.rubyonrails.org/">leader board</a></strong>. If you&#8217;re into that sort of ladder-climbing, you can break into a top 200 spot with just 8 commits. With just a bit of effort I reached 267th, which gets me laid <em>all </em>the time.</p>
<p>It feels damn good to give back to projects you use every day, and seeing your name in the commit logs is a real trip at first. If you&#8217;ve been looking to start making some open-source contributions, you could do a lot worse than improving documentation used by thousands.</p>
<p>If I&#8217;ve inspired you, <strong>you should start here: the <a href="http://edgeguides.rubyonrails.org/contributing_to_rails.html#contributing-to-the-rails-documentation">Contributing to Rails Guide</a></strong> has a section specifically for working on documentation. Good luck!</p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2011/02/how-to-land-your-first-patch-in-rails/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to use Rails routes in Steak scenarios (and RSpec specs)</title>
		<link>http://codeulate.com/2010/11/how-to-use-rails-routes-in-steak-scenarios-and-rspec-specs/</link>
		<comments>http://codeulate.com/2010/11/how-to-use-rails-routes-in-steak-scenarios-and-rspec-specs/#comments</comments>
		<pubDate>Fri, 19 Nov 2010 23:22:09 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=216</guid>
		<description><![CDATA[Want to use Rails&#8217; routes in your Steak scenarios (or any type of RSpec specs)? No problem. Here&#8217;s what you want: # In spec_helper.rb RSpec.configure do &#124;config&#124; # Make the rails routes available in all specs config.include Rails.application.routes.url_helpers # or # Make them available only in Steak scenarios config.include Rails.application.routes.url_helpers, :type =&#62; :acceptance end Fair [...]]]></description>
			<content:encoded><![CDATA[<p>Want to use Rails&#8217; routes in your Steak scenarios (or any type of RSpec specs)? No problem. Here&#8217;s what you want:</p>
<div class="codecolorer-container ruby vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:635px;"><div class="ruby codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color:#008000; font-style:italic;"># In spec_helper.rb</span><br />
<br />
RSpec.<span style="color:#9900CC;">configure</span> <span style="color:#9966CC; font-weight:bold;">do</span> <span style="color:#006600; font-weight:bold;">|</span>config<span style="color:#006600; font-weight:bold;">|</span><br />
<span style="color:#008000; font-style:italic;"># Make the rails routes available in all specs</span><br />
config.<span style="color:#9966CC; font-weight:bold;">include</span> Rails.<span style="color:#9900CC;">application</span>.<span style="color:#9900CC;">routes</span>.<span style="color:#9900CC;">url_helpers</span><br />
<br />
<span style="color:#008000; font-style:italic;"># or </span><br />
<br />
<span style="color:#008000; font-style:italic;"># Make them available only in Steak scenarios</span><br />
config.<span style="color:#9966CC; font-weight:bold;">include</span> Rails.<span style="color:#9900CC;">application</span>.<span style="color:#9900CC;">routes</span>.<span style="color:#9900CC;">url_helpers</span>, <span style="color:#ff3333; font-weight:bold;">:type</span> <span style="color:#006600; font-weight:bold;">=&gt;</span> <span style="color:#ff3333; font-weight:bold;">:acceptance</span><br />
<span style="color:#9966CC; font-weight:bold;">end</span></div></div>
<p>Fair warning: I&#8217;ve seen some folks say that you shouldn&#8217;t do this, and instead should define your routes in paths.rb. This way testing your routes is part of your acceptance suite.</p>
<p>I see where they&#8217;re coming from, but this just doesn&#8217;t seem worth it to me. I don&#8217;t find routes to be a very bug-prone area in my apps, so keeping duplicate my routes in two files is too high a price to pay.</p>
<p>I&#8217;ve been using Rails&#8217; built-in route helpers in my specs for several months now, and can&#8217;t think of a single routing issue that&#8217;s come up. YMMV.</p>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2010/11/how-to-use-rails-routes-in-steak-scenarios-and-rspec-specs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to teach programmers</title>
		<link>http://codeulate.com/2010/10/how-to-teach-programmers/</link>
		<comments>http://codeulate.com/2010/10/how-to-teach-programmers/#comments</comments>
		<pubDate>Sat, 16 Oct 2010 06:24:55 +0000</pubDate>
		<dc:creator>Ben Orenstein</dc:creator>
				<category><![CDATA[general]]></category>

		<guid isPermaLink="false">http://codeulate.com/?p=191</guid>
		<description><![CDATA[I just spent the last eight hours in a jQuery training class. I noticed that in some sections I was pretty bored, but in others I was completely engaged. After a while, I realized I could easily predict whether a section would be interesting or boring with the following heuristic: slides suck, code rocks. I [...]]]></description>
			<content:encoded><![CDATA[<div id="_mcePaste">I just spent the last eight hours in a <a href="http://loft.bocoup.com/intro-to-jquery-2010-10-15/">jQuery</a><a href="http://loft.bocoup.com/intro-to-jquery-2010-10-15/"> training class</a>. I noticed that in some sections I was pretty bored, but in others I was completely engaged.</div>
<p></p>
<div>After a while, I realized I could easily predict whether a section would be interesting or boring with the following heuristic: <strong>slides suck, code rocks</strong>.</div>
<p></p>
<div id="_mcePaste">I think we need to get away from the idea that a bunch of code snippets on slides is a good way to teach programmers. Think about this: if you needed to pick up a new language over the next week, how would you do it?  When programmers want to learn a new language, there&#8217;s really only one way we can really make progress: we play with it. We load up just a little bit of code, and we poke at it. A question pops into our heads and we find the answer with code. When we&#8217;ve got the basics, we start trying to build bigger things.</div>
<p></p>
<div>If this is the way programmers learn (and I claim that it is), why are we teaching them with snippets on a slide?</div>
<p></p>
<div>My favorite speaker of the day was <a href="http://benalman.com/">Ben</a><a href="http://benalman.com/">Alman</a>. Ben&#8217;s talks were fantastic for two reasons: first, he was ridiculously knowledgeable about his subject matter. But almost as importantly, he spent a ton of time writing code for us. Everything he talked about was demonstrated on the fly with code running in the browser. Someone asked a question? Ben wrote some code to show him the answer.</div>
<p></p>
<div>After Ben spent five minutes refactoring two functions, I realized I&#8217;d learned more in those five minutes than I had in the hour leading up to it. An hour spent reading examples off slides.</div>
<p></p>
<div>I&#8217;m starting to think that this should be the go-to move when teaching programmers. Write code in front of us, live. You&#8217;re allow to screw up; in fact, I hope you do! I&#8217;ll learn something watching you fix it. This is how you&#8217;d teach a friend who&#8217;d come by your desk for help. Let&#8217;s just pretend we&#8217;re already buddies, and show me some code.</div>
]]></content:encoded>
			<wfw:commentRss>http://codeulate.com/2010/10/how-to-teach-programmers/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

