<?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 github</title>
    <link>http://www.robbyonrails.com/articles/tag/github</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>thoughts.sort_by{|t| t[:topic]}.collect </description>
    <item>
      <title>ShortURL on Github</title>
      <description>&lt;p&gt;After noticing a few patch requests on Rubyforge.. I decided that I&amp;#8217;d put the ShortURL gem up on GitHub as I spend quite a bit of my time there these days. :-)&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;a href="http://github.com/robbyrussell/shorturl/tree"&gt;http://github.com/robbyrussell/shorturl/tree&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;I&amp;#8217;ve also thrown up a &lt;a href="http://gist.github.com/2186"&gt;few lines of code&lt;/a&gt; so that you can get the &lt;em&gt;gist&lt;/em&gt; of the gem. ;-)&lt;/p&gt;


&lt;script src="http://gist.github.com/2186.js"&gt;&lt;/script&gt;
</description>
      <pubDate>Thu, 24 Jul 2008 10:56:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:ae5b1e3e-e539-4451-8224-dec14d560e09</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2008/07/24/shorturl-on-github</link>
      <category>rubyurl</category>
      <category>shorturl</category>
      <category>gem</category>
      <category>git</category>
      <category>github</category>
      <category>gist</category>
    </item>
    <item>
      <title>RubyURL meets Zombies!</title>
      <description>&lt;p&gt;Last Friday, Greg Borenstein sent me a link to &lt;a href="http://zombieurl.com"&gt;ZombieURL&lt;/a&gt; after it got launched. The folks at &lt;a href="http://bottlecaplabs.net/"&gt;Bottlecap Labs&lt;/a&gt; took &lt;a href="http://rubyurl.com"&gt;RubyURL&lt;/a&gt; and threw in Zombies&amp;#8230; the rest you&amp;#8217;ll have to see for yourself.&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;a href="http://zombieurl.com/Ssfl"&gt;don&amp;#8217;t click this link&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;There&amp;#8230; I warned you.&lt;/p&gt;


	&lt;p&gt;You can check out the source code for ZombieURL on GitHub&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;a href="http://github.com/bottlecaplabs/zombieurl/tree"&gt;http://github.com/bottlecaplabs/zombieurl/tree&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;You can also grab the underlying source code for RubyURL on GitHub.&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;a href="http://github.com/robbyrussell/rubyurl/tree/master"&gt;http://github.com/robbyrussell/rubyurl/tree/master&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;I&amp;#8217;d love to see what other fun things people come up with to do with RubyURL.&lt;/p&gt;
</description>
      <pubDate>Tue, 22 Apr 2008 11:43:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:70c2e909-d2f1-4ecc-8c28-7edcfef5784e</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2008/04/22/rubyurl-meets-zombies</link>
      <category>RubyURL</category>
      <category>ruby</category>
      <category>development</category>
      <category>zombies</category>
      <category>rubyurl</category>
      <category>github</category>
    </item>
    <item>
      <title>git-svn is a gateway drug</title>
      <description>&lt;p&gt;As we&amp;#8217;re migrating away from Subversion to Git, I&amp;#8217;m having to learn a lot about &lt;code&gt;git-svn&lt;/code&gt;. Andy has &lt;a href="http://andy.delcambre.com/2008/3/4/git-svn-workflow"&gt;posted a few articles&lt;/a&gt; on this topic, but I wanted to share a quick tip that I find myself forgetting.&lt;/p&gt;


	&lt;h2&gt;Working with Subversion branches&lt;/h2&gt;


	&lt;p&gt;While you&amp;#8217;re hopefully already familiar with how great &lt;strong&gt;local branches&lt;/strong&gt; are with Git, you might not know that you can connect local branches to &lt;strong&gt;remote&lt;/strong&gt; branches in your Subversion repository. This allows those of us who are using Git locally to work against Subversion branches.&lt;/p&gt;


	&lt;p&gt;I&amp;#8217;m going to assume the following:&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;Your team is using Subversion&lt;/li&gt;
		&lt;li&gt;Your team already has a branch that you&amp;#8217;re working in&lt;/li&gt;
		&lt;li&gt;Your team is following Subversion directory conventions (&lt;code&gt;branches/&lt;/code&gt;, &lt;code&gt;tags/&lt;/code&gt;, and &lt;code&gt;trunk/&lt;/code&gt;)&lt;/li&gt;
		&lt;li&gt;You have Git installed (&lt;em&gt;with &lt;span class="caps"&gt;SVN&lt;/span&gt; extensions&lt;/em&gt;)&lt;/li&gt;
	&lt;/ul&gt;


	&lt;h3&gt;Checkout the Subversion project with Git&lt;/h3&gt;


	&lt;p&gt;Please visit Andy&amp;#8217;s tutorial, &lt;a href="http://andy.delcambre.com/2008/3/4/git-svn-workflow"&gt;Git &lt;span class="caps"&gt;SVN&lt;/span&gt; Workflow&lt;/a&gt;, for a more detailed explanation of the following commands.&lt;/p&gt;


	&lt;p&gt;First, we&amp;#8217;ll initialize your new local Git repository with &lt;code&gt;git-svn&lt;/code&gt;.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
  git svn init -s http://svn.yourdomain.com/repos/project_name
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Now, you&amp;#8217;ll change directories to your new Git repository.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
  cd project_name
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Let&amp;#8217;s fetch all previous revisions into your local repository&lt;sup&gt;&lt;a href="#fn1"&gt;1&lt;/a&gt;&lt;/sup&gt;.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
  git svn fetch
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Great, once this is done&amp;#8230; you&amp;#8217;re &lt;strong&gt;master&lt;/strong&gt; (local) branch is linked to &lt;code&gt;trunk/&lt;/code&gt;.&lt;/p&gt;


	&lt;h3&gt;Mapping a local repository to a remote branch&lt;/h3&gt;


	&lt;p&gt;Assuming that your team is working in a Subversion branch on the current iteration of work. Our team has a naming convention for branches for each iteration. For example, if we&amp;#8217;re in Iteration 18, we&amp;#8217;ll write this as &lt;span class="caps"&gt;ITER&lt;/span&gt;-018 everywhere (Basecamp, Lighthouse, Subversion, etc&amp;#8230;). At the start of each iteration, we create a new branch with this naming convention.&lt;/p&gt;


	&lt;p&gt;For &lt;code&gt;ITER-018&lt;/code&gt;, the Subversion branch would be located at:&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;http://svn.yourdomain.com/repos/project_name/branches/ITER-018&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;If you were to do a &lt;code&gt;git branch -r&lt;/code&gt;, you should see &lt;code&gt;ITER-018&lt;/code&gt; show up in the list. Now, the one thing that wasn&amp;#8217;t clear when I first read the &lt;code&gt;git-svn&lt;/code&gt; documentation was that you can&amp;#8217;t just checkout that branch with one command. In fact, this has tripped me up a few times.&lt;/p&gt;


	&lt;p&gt;First, you&amp;#8217;ll need to checkout a new &lt;em&gt;local&lt;/em&gt; branch. I&amp;#8217;ve opted to come up with my own convention for &lt;em&gt;local branches&lt;/em&gt; and in this case, I&amp;#8217;ll name it &lt;code&gt;iter_018&lt;/code&gt;.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
  git co -b iter_018
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;So, now I&amp;#8217;m in the iter_018 branch, which is local. I&amp;#8217;m currently still mapped to &lt;code&gt;trunk/&lt;/code&gt;, which isn&amp;#8217;t what we want. However, all we need to do is reset where Git is currently pointed to. We can run &lt;a href="http://andy.delcambre.com/2008/3/12/git-reset-in-depth"&gt;git reset&lt;/a&gt; to point this to the &lt;span class="caps"&gt;ITER&lt;/span&gt;-018 branch.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
  git reset --hard ITER-018
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;That&amp;#8217;s it! Now, the local &lt;code&gt;iter_018&lt;/code&gt; branch will point to &lt;code&gt;branches/ITER-018&lt;/code&gt; in your Subversion repository. This will allow you to work with your existing repository branch and still reap the benefits of local Git repositories.&lt;/p&gt;


	&lt;h3&gt;What about master?&lt;/h3&gt;


	&lt;p&gt;Good question. The &lt;code&gt;git reset&lt;/code&gt; command that you ran will &lt;span class="caps"&gt;ONLY&lt;/span&gt; apply that that individual local branch. So, master is &lt;em&gt;still&lt;/em&gt; pointing to &lt;code&gt;trunk/&lt;/code&gt;. This will allow you to have several local branches that map to remote branches.&lt;/p&gt;


	&lt;h2&gt;Next Steps&amp;#8230;&lt;/h2&gt;


	&lt;p&gt;If you&amp;#8217;re working with Git already.. great!&lt;/p&gt;


	&lt;p&gt;If you&amp;#8217;re working in an environment that using Subversion, &lt;code&gt;git svn&lt;/code&gt; provides you the ability to start exploring Git without making your entire team switchover. Perhaps your a consultant and working for a client that uses Subversion&amp;#8230; no problem!&lt;/p&gt;


	&lt;p&gt;We&amp;#8217;re still using Subversion for past client projects and are considering &lt;a href="http://github.com"&gt;GitHub&lt;/a&gt;, which &lt;a href="http://github.com/blog/40-we-launched"&gt;just launched (to the public) today&lt;/a&gt; for future projects. A few of us are already using GitHub for open source projects.&lt;/p&gt;


	&lt;p&gt;Fun.. I just saw the following tweet pass by as I began to wrap up this post.&lt;/p&gt;


&lt;div class="thumbnail"&gt;&lt;a href="http://skitch.com/robbyrussell/jeh1/rails-on-github"&gt;&lt;img src="http://img.skitch.com/20080411-rgageidq82ak6ij952ppant4u9.preview.jpg" alt="rails on github" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="font-family: Lucida Grande, Trebuchet, sans-serif, Helvetica, Arial; font-size: 10px; color: #808080"&gt;Uploaded with &lt;a href="http://plasq.com/"&gt;plasq&lt;/a&gt;&amp;#8217;s &lt;a href="http://skitch.com"&gt;Skitch&lt;/a&gt;!&lt;/span&gt;&lt;/div&gt;

	&lt;p&gt;&lt;a href="http://github.com/rails/"&gt;Check out Rails on GitHub!&lt;/a&gt;&lt;/p&gt;


	&lt;h3&gt;The Gateway Drug&amp;#8230; Git reminds me of Cake&lt;/h3&gt;


&lt;object width="425" height="355"&gt;&lt;param name="movie" value="http://www.youtube.com/v/g0GxUxKZdHk&amp;#38;hl=en"&gt;&lt;/param&gt;&lt;param name="wmode" value="transparent"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/g0GxUxKZdHk&amp;#38;hl=en" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"&gt;&lt;/embed&gt;&lt;/object&gt;

	&lt;h3&gt;Questions?&lt;/h3&gt;


	&lt;p&gt;I know that I glossed over a few things, so feel free to post questions and/or tips for others who are looking to dabble with Git.&lt;/p&gt;


	&lt;p id="fn1"&gt;&lt;sup&gt;1&lt;/sup&gt; You&amp;#8217;ll likely have problems if you don&amp;#8217;t have a Git authors file specified in your git config.&lt;/p&gt;
</description>
      <pubDate>Thu, 10 Apr 2008 22:28:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:cea369ee-eed9-4ec3-a0e9-91421f590dd7</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2008/04/10/git-svn-is-a-gateway-drug</link>
      <category>Ruby on Rails</category>
      <category>Programming</category>
      <category>PLANET ARGON</category>
      <category>git</category>
      <category>rubyonrails</category>
      <category>subversion</category>
      <category>github</category>
    </item>
    <item>
      <title>I am forking Rails</title>
      <description>&lt;p&gt;...well, creating a fork on GitHub. ;-)&lt;/p&gt;


&lt;div class="thumbnail"&gt;&lt;a href="http://skitch.com/robbyrussell/e32x/fork-rails"&gt;&lt;img src="http://img.skitch.com/20080402-7jfqp4wbc4h32q3cwysaincfa.preview.jpg" alt="fork rails" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="font-family: Lucida Grande, Trebuchet, sans-serif, Helvetica, Arial; font-size: 10px; color: #808080"&gt;Uploaded with &lt;a href="http://plasq.com/"&gt;plasq&lt;/a&gt;&amp;#8217;s &lt;a href="http://skitch.com"&gt;Skitch&lt;/a&gt;!&lt;/span&gt;&lt;/div&gt;

	&lt;p&gt;It appears that Rails is moving from Subversion to Git!&lt;/p&gt;


	&lt;p&gt;Courtenay posted &lt;a href="http://blog.caboo.se/articles/2008/4/2/it-s-official-rails-moves-to-git"&gt;this&lt;/a&gt; a little while ago.&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
git clone git://github.com/rails/rails.git
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;Check it out the &lt;a href="http://github.com/rails"&gt;Ruby on Rails project&lt;/a&gt; on GitHub.&lt;/p&gt;


	&lt;p&gt;Start working on your next patch with git&amp;#8230;&lt;/p&gt;


&lt;pre&gt;&lt;code&gt;
git clone git://github.com/rails/rails.git
cd rails
git br -a
git br my_patch
git co my_patch
&lt;/code&gt;&lt;/pre&gt;

	&lt;p&gt;This is cool news. :-)&lt;/p&gt;
</description>
      <pubDate>Wed, 02 Apr 2008 15:01:00 -0500</pubDate>
      <guid isPermaLink="false">urn:uuid:d06a69ee-8006-480f-92f7-6c0c3f53e9e6</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2008/04/02/forking-rails</link>
      <category>Ruby on Rails</category>
      <category>Ruby</category>
      <category>git</category>
      <category>rubyonrails</category>
      <category>subversion</category>
      <category>github</category>
    </item>
    <item>
      <title>Launch your own RubyURL</title>
      <description>&lt;p&gt;A few weeks ago, I moved &lt;a href="http://rubyurl.com"&gt;RubyURL&lt;/a&gt; from subversion to git. During that process, I decided to use my invite to &lt;a href="http://github.com"&gt;GitHub&lt;/a&gt; and have decided to go ahead and open up the source code.&lt;/p&gt;


	&lt;p&gt;It&amp;#8217;s currently a whopping 92 &lt;span class="caps"&gt;LOC&lt;/span&gt; with a 1:2.5 code to spec ratio. (I had a goal to keep is below 100 &lt;span class="caps"&gt;LOC&lt;/span&gt;)&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;RubyURL on GitHub: &lt;a href="http://github.com/robbyrussell/rubyurl"&gt;http://github.com/robbyrussell/rubyurl&lt;/a&gt;&lt;/li&gt;
		&lt;li&gt;Public Clone &lt;span class="caps"&gt;URL&lt;/span&gt;: &lt;a href="git://github.com/robbyrussell/rubyurl.git"&gt;git://github.com/robbyrussell/rubyurl.git&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;Feel free to grab it and help contribute. This has served almost &lt;strong&gt;14 million&lt;/strong&gt; redirects since August 2007 and is running on a &lt;a href="http://planetargon.com/hosting.html"&gt;Rails Boxcar&lt;/a&gt;.&lt;/p&gt;


	&lt;p&gt;To grab it with git.. run: &lt;code&gt;git clone git://github.com/robbyrussell/rubyurl.git&lt;/code&gt;.&lt;/p&gt;


	&lt;p&gt;Feel free to submit tickets to the &lt;a href="http://planetargon.lighthouseapp.com/projects/4059-rubyurl"&gt;Rubyurl ticket system&lt;/a&gt;.&lt;/p&gt;


	&lt;ul&gt;
	&lt;li&gt;&lt;a href="http://planetargon.lighthouseapp.com/projects/4059-rubyurl"&gt;http://planetargon.lighthouseapp.com/projects/4059-rubyurl&lt;/a&gt;&lt;/li&gt;
	&lt;/ul&gt;


	&lt;p&gt;Enjoy!&lt;/p&gt;


	&lt;p&gt;&lt;strong&gt;&lt;span class="caps"&gt;UPDATE&lt;/span&gt;&lt;/strong&gt; Ryan McGeary was kind enough to be the first person to help track down a bug and &lt;a href="http://github.com/robbyrussell/rubyurl/commits/master"&gt;submit patches&lt;/a&gt;. :-)&lt;/p&gt;
</description>
      <pubDate>Sat, 01 Mar 2008 18:31:00 -0600</pubDate>
      <guid isPermaLink="false">urn:uuid:a1e839d1-4c9b-47d6-931c-b0559ea71539</guid>
      <author>Robby Russell</author>
      <link>http://www.robbyonrails.com/articles/2008/03/01/launch-your-own-rubyurl</link>
      <category>RubyURL</category>
      <category>Ruby on Rails</category>
      <category>Programming</category>
      <category>PLANET ARGON</category>
      <category>rubyurl</category>
      <category>boxcar</category>
      <category>git</category>
      <category>subversion</category>
      <category>github</category>
      <category>open</category>
      <category>source</category>
      <category>rails</category>
      <category>rspec</category>
    </item>
  </channel>
</rss>
