<?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>Jer on Rails</title>
	<atom:link href="http://blog.weiskotten.com/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.weiskotten.com</link>
	<description>Jeremy Weiskotten on web development, startups, beer, and other stuff.</description>
	<lastBuildDate>Sat, 22 Jan 2011 15:47:33 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
		<item>
		<title>Priorities</title>
		<link>http://blog.weiskotten.com/2011/01/priorities.html</link>
		<comments>http://blog.weiskotten.com/2011/01/priorities.html#comments</comments>
		<pubDate>Sat, 22 Jan 2011 15:47:33 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[agile]]></category>
		<category><![CDATA[prioritization]]></category>

		<guid isPermaLink="false">http://blog.weiskotten.com/?p=58</guid>
		<description><![CDATA[My two simple rules for prioritizing work.]]></description>
			<content:encoded><![CDATA[<ol>
<li><strong>Given two tasks, determine which is of greater business value and do that one first. If a team member working on a task of greater value than your current task needs your help, stop what you are doing and help them. <em>Focus on delivering value.
<p></em></strong></li>
<li><strong>Given two tasks of about equal business value, do the riskier one first. </strong><em><strong>Eliminate risks as soon as possible.</strong></em></li>
</ol>
<p>Those are my two simple rules for prioritizing work. It&#8217;s up to you and your team to determine how you measure business value and risk.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2011/01/priorities.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New blog!</title>
		<link>http://blog.weiskotten.com/2011/01/new-blog.html</link>
		<comments>http://blog.weiskotten.com/2011/01/new-blog.html#comments</comments>
		<pubDate>Sat, 15 Jan 2011 01:36:49 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.weiskotten.com/?p=49</guid>
		<description><![CDATA[Just moved from Blogger to a self-managed WordPress installation. I&#8217;m using a theme based on &#8220;Save-As&#8221; created by friends Adam Darowski and Cris Necochea.]]></description>
			<content:encoded><![CDATA[<p>Just moved from Blogger to a self-managed WordPress installation. I&#8217;m using a theme based on &#8220;<a href="http://tech.patientslikeme.com/2010/11/24/save-as-a-basic-html5-wordpress-template/">Save-As</a>&#8221; created by friends <a href="http://twitter.com/adarowski">Adam Darowski</a> and <a href="http://twitter.com/knick44">Cris Necochea</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2011/01/new-blog.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>strftime reference and sandbox for Ruby, Python, PHP</title>
		<link>http://blog.weiskotten.com/2010/06/formatting-dates-and-times-with-strftime.html</link>
		<comments>http://blog.weiskotten.com/2010/06/formatting-dates-and-times-with-strftime.html#comments</comments>
		<pubDate>Fri, 18 Jun 2010 01:45:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[strftime]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2010/06/formatting-dates-and-times-with-strftime/</guid>
		<description><![CDATA[Whenever I want to format a date or time in Ruby, or add a format to DATE_FORMATS in a Rails app, I resort to Google to look up the options for the strftime function. I&#8217;ve never really been happy with the quality or readability of the references that are on the web, so I made [...]]]></description>
			<content:encoded><![CDATA[<p>Whenever I want to format a date or time in Ruby, or add a format to DATE_FORMATS in a Rails app, I resort to Google to look up the options for the <a href="http://strfti.me">strftime</a> function. I&#8217;ve never really been happy with the quality or readability of the references that are on the web, so I made my own along with a simple sandbox to try different formats with the current time.</p>
<p style="text-align: center;"><a href="http://strfti.me"><img class="aligncenter" title="http://strfti.me" src="http://blog.weiskotten.com/wp-content/uploads/2010/06/strftime.png" alt="Screenshot of http://strfti.me" width="260" height="195" /></a></p>
<p>Check out <a href="http://strfti.me">http://strfti.me</a> and let me know if you find it useful!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2010/06/formatting-dates-and-times-with-strftime.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A Kick in the Sass: Making slow functional tests faster</title>
		<link>http://blog.weiskotten.com/2009/12/a-kick-in-the-sass-making-slow-functional-tests-faster.html</link>
		<comments>http://blog.weiskotten.com/2009/12/a-kick-in-the-sass-making-slow-functional-tests-faster.html#comments</comments>
		<pubDate>Tue, 08 Dec 2009 16:28:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[rails]]></category>
		<category><![CDATA[sass]]></category>
		<category><![CDATA[testing]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/12/a-kick-in-the-sass-making-slow-functional-tests-faster/</guid>
		<description><![CDATA[We started using Sass a while ago for all new styles, and recently converted all of our CSS to Sass. We noticed that after the conversion to Sass our test suite was suddenly taking a lot longer to run, in the neighborhood of 50% longer. Specifically, our functional and integration tests were a lot slower. [...]]]></description>
			<content:encoded><![CDATA[<p>We started using <a href="http://sass-lang.com/">Sass</a> a while ago for all new styles, and recently converted all of our CSS to Sass. We noticed that after the conversion to Sass our test suite was suddenly taking a lot longer to run, in the neighborhood of 50% longer. Specifically, our functional and integration tests were a <span style="font-weight:bold;">lot</span> slower.</p>
<p>
<p><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_Gdc6BUabwRo/Sx6C3NlDASI/AAAAAAAAB4Y/5BGkflwn-WA/s1600-h/3368034717_d15afa2973.jpg"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 261px;" src="http://4.bp.blogspot.com/_Gdc6BUabwRo/Sx6C3NlDASI/AAAAAAAAB4Y/5BGkflwn-WA/s400/3368034717_d15afa2973.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5412907687195377954" /></a></p>
<p>
<p>It turns out that, out of the box, Sass updates the &#8220;compiled&#8221; stylesheets on every request unless you&#8217;re running in production mode. This is really handy in development when you&#8217;re making incremental edits in a .sass file and refreshing the browser to see the results, but it&#8217;s completely unnecessary when running tests since the .sass files aren&#8217;t changing while the tests are running, and chances are your functional tests aren&#8217;t dependent on any CSS files anyway.</p>
<p>
<p>To change this behavior in our test environment, we added the following to config/environments/test.rb:</p>
<p><script src="http://gist.github.com/251766.js"></script><br />Now Sass will only compile the stylesheets once (the first time one is needed), and our entire test suite is about 60% faster (YMMV).
<p><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_Gdc6BUabwRo/Sx6Bx0f5jnI/AAAAAAAAB4Q/7Mx0xnlxQr8/s1600-h/D737~Speed-Racer-Go-Speed-Posters.jpg"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 312px;" src="http://1.bp.blogspot.com/_Gdc6BUabwRo/Sx6Bx0f5jnI/AAAAAAAAB4Q/7Mx0xnlxQr8/s400/D737~Speed-Racer-Go-Speed-Posters.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5412906495051927154" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/12/a-kick-in-the-sass-making-slow-functional-tests-faster.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The worst wide receiver in professional football: ME?</title>
		<link>http://blog.weiskotten.com/2009/12/the-worst-wide-receiver-in-professional-football-me.html</link>
		<comments>http://blog.weiskotten.com/2009/12/the-worst-wide-receiver-in-professional-football-me.html#comments</comments>
		<pubDate>Tue, 08 Dec 2009 04:14:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[interview]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/12/the-worst-wide-receiver-in-professional-football-me/</guid>
		<description><![CDATA[I was recently interviewed for EcontentMag. Strange being referred to as &#8220;Weiskotten&#8221;, but now I&#8217;m a little more Internet-famous! If you&#8217;re bored, check it out.]]></description>
			<content:encoded><![CDATA[<p>I was recently interviewed for EcontentMag. Strange being referred to as &#8220;Weiskotten&#8221;, but now I&#8217;m a little more Internet-famous!</p>
<p>If you&#8217;re bored, <a href="http://www.econtentmag.com/Articles/Editorial/Faces-of-Econtent/Jeremy-Weiskotten,-Senior-Software-Engineer,-PatientsLikeMe-57947.htm">check it out</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/12/the-worst-wide-receiver-in-professional-football-me.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hiring Rails Developers and QA</title>
		<link>http://blog.weiskotten.com/2009/10/hiring-rails-developers-and-qa.html</link>
		<comments>http://blog.weiskotten.com/2009/10/hiring-rails-developers-and-qa.html#comments</comments>
		<pubDate>Tue, 27 Oct 2009 23:27:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[careers]]></category>
		<category><![CDATA[jobs]]></category>
		<category><![CDATA[PatientsLikeMe]]></category>
		<category><![CDATA[qa]]></category>
		<category><![CDATA[rails]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/10/hiring-rails-developers-and-qa/</guid>
		<description><![CDATA[PatientsLikeMe is growing! We&#8217;re looking for a few great Rails developers. If you don&#8217;t know Rails but are eager to learn, start learning now and get in touch. We&#8217;re also looking for an experienced QA engineer to keep us honest and help us with automated acceptance/regression testing, among other things. To get you psyched up [...]]]></description>
			<content:encoded><![CDATA[<p><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_Gdc6BUabwRo/SueSlhLrk_I/AAAAAAAAB4I/_dGRn9Lh0x0/s1600-h/18127v1-max-250x250.png"><img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer; width: 250px; height: 48px;" src="http://3.bp.blogspot.com/_Gdc6BUabwRo/SueSlhLrk_I/AAAAAAAAB4I/_dGRn9Lh0x0/s400/18127v1-max-250x250.png" alt="" id="BLOGGER_PHOTO_ID_5397443851687007218" border="0" /></a>PatientsLikeMe is <a href="http://www.patientslikeme.com/about/careers">growing</a>! We&#8217;re looking for a few great Rails developers. If you don&#8217;t know Rails but are eager to learn, <a href="http://www.rubyonrails.org/">start</a> <a href="http://railscasts.com/">learning</a> <a href="http://www.amazon.com/Agile-Web-Development-Rails-Programmers/dp/097669400X">now</a> and get in touch.</p>
<p>We&#8217;re also looking for an experienced QA engineer to keep us honest and help us with automated acceptance/regression testing, among other things.</p>
<p>To get you psyched up about coming to work with us, I thought I&#8217;d share a little about our team, our culture, and how we get things done.</p>
<p>We have a couple of amazing designers on staff, <a href="http://www.patientslikeme.com/members/view/3172">Kate</a> and <a href="http://www.patientslikeme.com/members/view/6751">Scott</a>. We get to bring their works of art to life. Kate has lots of insight into usability and user testing, and Scott brings a wealth of knowledge about visualizations (and he <a href="http://astronautdinosaur.com/">paints astronauts</a>, which is awesome).</p>
<p>We still support IE6. Yeah, that sucks, but a good chunk of our users (mostly patients) still use it. Lucky for us, <a href="http://www.patientslikeme.com/members/view/91">Cris</a> and <a href="http://www.patientslikeme.com/members/view/adarowski">Adam</a> know all the tricks. Semantic markup, IE hacks, accessibility&#8230; we&#8217;ve got it all. Well, except <a href="http://mobihealthnews.com/1370/whcc-patientslikeme-doesnt-like-mobile/">mobile</a>, but that can change.</p>
<p>We do all kinds of crazy, awesome things in our free time. You already know about Scott&#8217;s astro-art. I created <a href="http://www.twackit.com/">Twackit</a> to play around with the Twitter API. <a href="http://www.patientslikeme.com/members/view/18959">James</a> created a really cool <a href="http://www.monkeyatlarge.com/archives/2009/08/30/day-in-the-life-of-the-mbta-system/">visualization of the MBTA system</a>. <a href="http://www.patientslikeme.com/members/view/804">Steve</a> is a Solar System Ambassador for the NASA Jet Propulsion Lab and a school committee member. <a href="http://www.patientslikeme.com/members/view/16596">Jeff &#8220;Mav&#8221; Dwyer</a> wrote a <a href="http://www.amazon.com/Pro-Web-Application-Development-ebook/dp/B001DA9MT6">book about GWT</a> (don&#8217;t worry, we won&#8217;t make you read it) and hands out Google Wave invites like they&#8217;re candy. <a href="http://www.patientslikeme.com/members/view/2739">Rich</a> helped Dan Cederholm (yes, <span style="font-style: italic;">the</span> Dan Cederholm) build <a href="http://dribbble.com">Dribbble</a>, and he <span style="font-style: italic;">barely</span> beat me in the finals of our Darts Madness tournament. <a href="http://www.patientslikeme.com/members/view/18128">Joe</a>, Kate and I helped get <a href="http://www.healthdatarights.org/">HealthDataRights.org</a> off the ground. Joe, Steve, Cris, and I participated in last year&#8217;s Rails Rumble and launched <a href="http://www.quest-for-life.org/">The Quest for Life</a>. I&#8217;m sure I&#8217;m forgetting someone or something, but that should give you an idea of how we roll.</p>
<p>Also, everyone loves Star Trek IV but me &#8212; that&#8217;s the one where they go back in time to save the humpback whales, which is stupid.</p>
<p>We have an in-house <a href="http://www.patientslikeme.com/research">research</a> team that sometimes makes me feel like I don&#8217;t know shit about shit. The stack of journal publications and presentations of their research can probably be blamed for most of the deforestation of the past 10 years. Our researchers help us figure out what data is interesting to patients and what&#8217;s interesting for research purposes, and they make sure we ask the right questions the right way (something about science and bias and blah blah, etc.).</p>
<p>Everyone has a MacBook Pro and an external monitor. We use VirtualBox to do IE testing. Some of us commute from out of town so we usually telecommute a couple days a week, but we stay in touch with IM and Campfire.</p>
<p>We use Git for version control. It&#8217;s pretty awesome. It&#8217;s super-easy to work on branches. We&#8217;re always creating remote branches to work on new features in isolation, and short-lived local branches for quick bug fixes.</p>
<p>We release in 2 week iterations. Fast enough to get stuff out, not so fast you lose track of what&#8217;s going on.</p>
<p>There&#8217;s still a lot of legacy stuff that uses ERB and regular CSS, but all our new stuff is Haml and Sass.</p>
<p>We have  dartboard that gets a lot of use, a Nintendo Wii (with Rock Band, of course), and we&#8217;ve been known to watch an episode of Star Trek or a certain movie featuring The Dude after work while we sip White Russians (or Caucasians, if you prefer). Three desks double as a conference room table which doubles as a ping pong table, and lo the balls fly furiously.</p>
<p>It&#8217;s rare to find a job that&#8217;s challenging, fun, or makes a difference in people&#8217;s lives, but PatientsLikeMe offers all of that in one place. A really great perk of working at PatientsLikeMe is that we have an opportunity to improve the lives of real people &#8212; thousands of patients with life-changing conditions. They&#8217;re a very involved user-base, with no shortage of ideas and feedback.</p>
<p>Oh, and we have direct deposit! You gotta have direct deposit.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/10/hiring-rails-developers-and-qa.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting up a Rails development environment on Leopard</title>
		<link>http://blog.weiskotten.com/2009/10/setting-up-a-rails-development-environment-on-leopard.html</link>
		<comments>http://blog.weiskotten.com/2009/10/setting-up-a-rails-development-environment-on-leopard.html#comments</comments>
		<pubDate>Sat, 17 Oct 2009 19:43:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[leopard]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[rails]]></category>
		<category><![CDATA[setup]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/10/setting-up-a-rails-development-environment-on-leopard/</guid>
		<description><![CDATA[I recently set up a new Rails environment on Mac OS X 10.5 (Leopard). I googled for various bits and pieces. I have no idea how much of this translates to 10.6 (Snow Leopard). I leaned on MacPorts to install Git, Ruby, RubyGems, PostgreSQL, and some other stuff that my Rails work depends on. Xcode [...]]]></description>
			<content:encoded><![CDATA[<p>I recently set up a new Rails environment on Mac OS X 10.5 (Leopard). I googled for various bits and pieces. <span style="font-weight: bold;">I have no idea how much of this translates to 10.6 (Snow Leopard).</span></p>
<p>I leaned on MacPorts to install Git, Ruby, RubyGems, PostgreSQL, and some other stuff that my Rails work depends on.</p>
<p><span style="font-weight: bold;font-size:100%;" >Xcode and MacPorts</span>
<ol>
<li>Install Xcode from OSX DVD.</li>
<li>Install MacPorts via http://www.macports.org/install.php</li>
</ol>
<p><span style="font-weight: bold;">Git</span>
<ol>
<li>sudo port install git-core +svn+bash_completion+doc</li>
</ol>
<p>To configure Git, including some handy aliases, add the following to ~/.gitconfig:</p>
<p>[user]<br />  email = {your@email.com}<br />  name = {Your Name}<br />[core]<br />  editor = mate -w<br />[color]<br />  status = auto<br />  diff = auto<br />  branch = auto<br />[alias]<br />  co = checkout<br />  st = status<br />  ci = commit<br />  df = !git diff | mate<br />[push]<br />  default = tracking</p>
<p>To enable bash_completion, add the following lines to the end of your .bash_profile or .profile:</p>
<p>  if [ -f /opt/local/etc/bash_completion ]; then<br />      . /opt/local/etc/bash_completion<br />  fi</p>
<p><span style="font-weight: bold;">Ruby 1.8.7 and RubyGems</span>
<ol>
<li>sudo port install ruby</li>
<li>sudo port install rb-rubygems</li>
</ol>
<p>(Note that gems will be installed to /opt/local/lib/ruby/gems/1.8.)</p>
<p><span style="font-weight: bold;">Symlink /usr/local/bin/ruby to MacPorts install</span>
<ol>
<li>sudo ln -s /opt/local/bin/ruby /usr/local/bin/ruby</li>
</ol>
<p><span style="font-weight: bold;">ImageMagick and RMagick</span><br />http://rmagick.rubyforge.org/install-osx.html
<ol>
<li>sudo port install imagemagick +gs +q16</li>
<li>sudo gem install rmagick</li>
</ol>
<p><span style="font-weight: bold;">PostgreSQL</span> 8.3<br />http://shifteleven.com/articles/2008/03/21/installing-postgresql-on-leopard-using-macports
<ol>
<li>sudo port install postgresql83 postgresql83-server</li>
<li>sudo mkdir -p /opt/local/var/db/postgresql83/defaultdb</li>
<li>sudo chown postgres:postgres /opt/local/var/db/postgresql83/defaultdb</li>
<li>sudo su postgres -c &#8216;/opt/local/lib/postgresql83/bin/initdb -D /opt/local/var/db/postgresql83/defaultdb&#8217;</li>
</ol>
<p>And so that pg server launches at system startup&#8230;
<ol>
<li>sudo launchctl load -w /Library/LaunchDaemons/org.macports.postgresql83-server.plist</li>
</ol>
<p><span style="font-weight: bold;">PostgreSQL Ruby adapter</span>
<ol>
<li>sudo env ARCHFLAGS=&#8221;-arch i386&#8243; gem install postgres &#8212; &#8211;with-pgsql-lib=/opt/local/lib/postgresql83 &#8211;with-pgsql-include=/opt/local/include/postgresql83</li>
</ol>
<p><span style="font-weight: bold;">Sphinx</span>
<ol>
<li>sudo port install sphinx +postgresql83</li>
</ol>
<p><span style="font-weight: bold;">Common gems</span>
<ol>
<li>sudo gem install rails fastercsv redgreen git_remote_branch capistrano capistrano-ext ruby-debug ruby-prof sqlite3-ruby</li>
</ol>
<p><span style="font-weight: bold;">SSH key</span>
<ol>
<li>ssh-keygen (Enter to select all defaults)</li>
<li>Add public key to GitHub account.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/10/setting-up-a-rails-development-environment-on-leopard.html/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>My Git Workflow</title>
		<link>http://blog.weiskotten.com/2009/04/my-git-workflow.html</link>
		<comments>http://blog.weiskotten.com/2009/04/my-git-workflow.html#comments</comments>
		<pubDate>Thu, 30 Apr 2009 00:23:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[git]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/04/my-git-workflow/</guid>
		<description><![CDATA[(Or, how I learned to stop worrying and love the Git.) Git is awesome. If you&#8217;re using it, you know what I mean. If you&#8217;re not, don&#8217;t be afraid to give it a try! Git is the gateway to a new generation of code sharing on GitHub and convenient deployment to Heroku. It&#8217;s built around [...]]]></description>
			<content:encoded><![CDATA[<p>(Or, how I learned to stop worrying and love the Git.)</p>
<p><a style="font-weight: bold;" href="http://whygitisbetterthanx.com/">Git is awesome</a><span style="font-weight: bold;">.</span> If you&#8217;re using it, you know what I mean. If you&#8217;re not, don&#8217;t be afraid to <a href="http://gitready.com/">give it a try</a>! Git is the gateway to a new generation of code sharing on GitHub and convenient deployment to Heroku. It&#8217;s built around fast branching, so it&#8217;s really easy (and did I mention fast?) to create and throw away experimental branches.</p>
<p>I&#8217;m pretty new to Git. I used it a bit in the past (with GitHub) but hadn&#8217;t really gotten into it until the past month or so when we made the switch at PatientsLikeMe from Subversion. It took me a couple of weeks to really understand what was going on, feel comfortable, and settle into a rhythm and workflow. This post will probably be old news to Git veterans, but I think there are enough Git noobs still out there that some will find this interesting or valuable (let me know if you&#8217;re one of them!).</p>
<p>Here&#8217;s how I use Git day-to-day, whether for new feature development or fixing bugs:</p>
<p><span style="font-weight: bold;">A. Work </span>in a local branch
<ol>
<li>git checkout -b <span style="font-style: italic;">dev-branch-name</span> (to create and switch to a local branch, where &#8220;dev-branch-name&#8221; is something meaningful)</li>
<li>Do some awesome (more or less) work.</li>
<li>git status, git add, git commit -am &#8220;Something about what I did&#8221;</li>
</ol>
<p><span style="font-weight: bold;">B. Integrate</span> with the latest
<ol>
<li>git checkout master</li>
<li>git pull (gets the stuff my teammates have pushed)</li>
<li>git checkout <span style="font-style: italic;">dev-branch-name</span></li>
<li>git rebase master (integrates my work with my teammates&#8217;)</li>
<li>Run the test suite.</li>
</ol>
<p><span style="font-weight: bold;">C. Merge</span> with the rest of the team
<ol>
<li>git checkout master</li>
<li>git merge <span style="font-style: italic;">dev-branch-name</span></li>
<li>git push</li>
</ol>
<p>It looks like a lot of steps and a lot to remember, but you can automate much of it if you&#8217;d like to save some keystrokes. I still like to go through the motions. You could use a simpler, more traditional (read: SVN) workflow, doing all of your work in master, but then you&#8217;re missing out on a lot of the benefit of Git.</p>
<p>To make git a bit more user-friendly, I set up most of the aliases suggested by <a href="http://justinfrench.com/index.php?id=253">Justin French</a>, so I actually use &#8220;git co&#8221; for checkout and &#8220;git ci&#8221; for commit, and I have a git completion bash script set up so that I don&#8217;t have to type out full branch names.</p>
<p>Switching between master and various local branches can get a bit confusing. To keep myself on track, and to try to avoid working in the wrong branch, I set up a <a href="http://github.com/guides/put-your-git-branch-name-in-your-shell-prompt">shell prompt</a> that displays the current branch for the git-aware working directory that I&#8217;m in. Here&#8217;s the actual prompt I&#8217;m using:</p>
<p><code><br />function parse_git_branch<br />{<br />ref=$(git-symbolic-ref HEAD 2> /dev/null) || return<br />echo ${ref#refs/heads/}<br />}<br />export PS1='\[\033[0;34m\]\A \[\033[00m\]\w \[\033[01;31m\]$(parse_git_branch)\[\033[00m\] $ '<br /></code></p>
<p>I&#8217;ve also started using <a href="http://github.com/webmat/git_remote_branch/tree/master">grb</a> to make working with (read: tracking) remote branches easier. It&#8217;s easy to install and has good documentation to get you started. Then there&#8217;s <a href="http://gitx.frim.nl/">GitX</a>, a powerful tool to browse your repository and to see which code is on what branches. I don&#8217;t lean on GitX as much as I could, but it comes in handy.</p>
<p>There&#8217;s a lot about Git that I still need to learn, so please leave a comment with your tips and tricks.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/04/my-git-workflow.html/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Announcing Twackit</title>
		<link>http://blog.weiskotten.com/2009/04/announcing-twackit.html</link>
		<comments>http://blog.weiskotten.com/2009/04/announcing-twackit.html#comments</comments>
		<pubDate>Tue, 21 Apr 2009 17:34:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[twackit]]></category>
		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/04/announcing-twackit/</guid>
		<description><![CDATA[Last weekend I launched Twackit, which gives you a simple way to use Twitter to keep track of different kinds of metrics that are important to you&#8230; stuff like your weight, gas mileage, expenses, caloric intake, hours of sleep &#8212; pretty much anything with a simple numeric value and a hashtaggable category that you might [...]]]></description>
			<content:encoded><![CDATA[<p><a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://twackit.com/"><img style="margin: 0pt 0pt 10px 10px; float: right; cursor: pointer; width: 265px; height: 301px;" src="http://2.bp.blogspot.com/_Gdc6BUabwRo/Se4MDfhoIzI/AAAAAAAABxY/26jOHdrghj8/s400/screenshot_thumbnail.png" alt="" id="BLOGGER_PHOTO_ID_5327208663367557938" border="0" /></a><br /><span style="font-weight: bold;">Last weekend I launched </span><a style="font-weight: bold;" href="http://twackit.com/">Twackit</a>, which gives you a simple way to use Twitter to keep track of different kinds of metrics that are important to you&#8230; stuff like your weight, gas mileage, expenses, caloric intake, hours of sleep &#8212; pretty much anything with a simple numeric value and a hashtaggable category that you might want to keep track of over time.</p>
<p>There&#8217;s some basic content and <a href="http://twackit.com/doctorzaius/weight">reports</a> are generated from the data you tweet to @<a href="http://twitter.com/twackit">twackit</a>. I&#8217;ve gotten some good feedback, and a couple people are already using it for things I never thought of, which is really cool! I wanted to get something simple up and running and try to get people using it, then see what kinds of requirements shake out from real-world use cases.</p>
<p>Since this is a Rails-oriented blog, I thought I&#8217;d share a few technical details:
<ol>
<li>Twackit is running on <span style="font-weight: bold;">Rails 2.3.2</span>, the current stable version.</li>
<li>I&#8217;m using <span style="font-weight: bold;">SQLite3</span> for development, but Heroku ignores your database.yml and uses Postgres, which is cool with me.</li>
<li>It&#8217;s hosted on <a style="font-weight: bold;" href="http://www.heroku.com/">Heroku</a>, which was very easy to set up in part because&#8230;</li>
<li>I&#8217;m using <span style="font-weight: bold;">Git</span> for version control. The code is not open source (at least not yet), and I&#8217;m only using a local repo, so no GitHub.</li>
<li>I used <a style="font-weight: bold;" href="http://haml.hamptoncatlin.com/">Haml</a> for the layout and views, except for a few partials that encapsulate HTML and Javascript for third-party stuff, like Google Analytics and UserVoice. I just pasted their code into ERB templates.</li>
<li>The reports use the <span style="font-weight: bold;">Google Visualization API</span> for things like the Annotated Time Line, which is really cool but not very useful until you have a lot of data. (So start adding data, everyone!)</li>
<li>The Annotated Time Line wants Javascript Date objects. Unfortunately, Rails implements Date#to_json to return a String representation of the date, so I ended up hacking it to build a String of the form &#8220;new Date(year, month, day)&#8221;. I&#8217;ll keep looking for a better way.</li>
<li>I used <a style="font-weight: bold;" href="http://railstips.org/">John Nunemaker</a><span style="font-weight: bold;">&#8216;s </span><a style="font-weight: bold;" href="http://github.com/jnunemaker/twitter/tree/master">Twitter gem</a> to call the Twitter search API and to get the user&#8217;s name and photo URL to make the report a little prettier.</li>
<li>Twackit searches for new tweets every hour or so. To support very basic background jobs, Heroku invokes a rake task named &#8220;cron&#8221; (which I think is a terrible choice because of the name collision, but at least it&#8217;s intuitive).</li>
<li>The cron rake task records some stats about each cron import, like how long it took, how many tweets were imported, and for how many distinct users. The task finishes in less than a second, since there isn&#8217;t much data coming in (yet!).</li>
</ol>
<p>So please check <a href="http://twackit.com/">Twackit</a> out and let me know what you think. And of course, <a href="http://twitter.com/home?status=Check%20out%20http://twackit.com%20to%20find%20out%20how%20to%20track%20different%20metrics%20and%20observe%20trends%20over%20time">tell everyone about it</a>!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/04/announcing-twackit.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Generating TinyURLs from Rails</title>
		<link>http://blog.weiskotten.com/2009/01/generating-tinyurls-from-rails.html</link>
		<comments>http://blog.weiskotten.com/2009/01/generating-tinyurls-from-rails.html#comments</comments>
		<pubDate>Sun, 11 Jan 2009 21:36:00 +0000</pubDate>
		<dc:creator>Jeremy Weiskotten</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://weiskotten.com/blog/2009/01/generating-tinyurls-from-rails/</guid>
		<description><![CDATA[Sometimes URLs are just too long, especially if you have constraints like the 140 character limit on Twitter. Free services like TinyURL have been around for years, providing short URLs that issue a permanent redirect to the long URL.TinyURL has a micro-API. Issuing a simple HTTP GET request to: http://tinyurl.com/api-create.php?url=http://www.myreallyreallylongurl.com/its-really-long renders a response like: http://tinyurl.com/8y94xz [...]]]></description>
			<content:encoded><![CDATA[<p>Sometimes URLs are just too long, especially if you have constraints like the 140 character limit on <a href="http://www.twitter.com/">Twitter</a>. Free services like <a href="http://www.tinyurl.com/">TinyURL</a> have been around for years, providing short URLs that issue a permanent redirect to the long URL.<br />TinyURL has a micro-API. Issuing a simple HTTP GET request to:</p>
<p><span style="font-weight: bold;font-size:85%;" ><span style="font-family: courier new;">http://tinyurl.com/api-create.php?url=http://www.myreallyreallylongurl.com/its-really-long</span></span></p>
<p>renders a response like:</p>
<p><span style="font-weight: bold;font-size:85%;" ><span style="font-family: courier new;">http://tinyurl.com/8y94xz</span></span></p>
<p>I recently created a Ruby on Rails plugin called <a href="http://github.com/jeremyw/tinify_urls">tinify_urls</a> that encapsulates this kind of thing, supporting the TinyURL, <a href="http://snipurl.com/">SnipURL</a>, and <a href="http://is.gd/">is.gd</a> APIs. The plugin has been tested against Rails 2.1.</p>
<p>I&#8217;m looking forward to feedback so <a href="mailto:jeremy@weiskotten.com">let me know</a> if you have a chance to try it out. To install the plugin:</p>
<p><span style="font-weight: bold;font-size:85%;" ><span style="font-family: courier new;">script/plugin install git://github.com/jeremyw/tinify_urls.git</span></span></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.weiskotten.com/2009/01/generating-tinyurls-from-rails.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

