<?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>Tea-Driven Development &#187; windows</title>
	<atom:link href="http://blog.mattwynne.net/tag/windows/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.mattwynne.net</link>
	<description>Matt Wynne taking it one tea at a time</description>
	<lastBuildDate>Tue, 10 Jan 2012 20:07:10 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Installing Ruby Gems with Native Extensions on Windows</title>
		<link>http://blog.mattwynne.net/2010/10/12/installing-ruby-gems-with-native-extensions-on-windows/</link>
		<comments>http://blog.mattwynne.net/2010/10/12/installing-ruby-gems-with-native-extensions-on-windows/#comments</comments>
		<pubDate>Tue, 12 Oct 2010 16:08:10 +0000</pubDate>
		<dc:creator>Matt</dc:creator>
				<category><![CDATA[Ruby Programming]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://blog.mattwynne.net/2010/10/12/installing-ruby-gems-with-native-extensions-on-windows/</guid>
		<description><![CDATA[If you&#8217;re stuck trying to run Ruby on Windows, one barrier you might have encountered is in trying to install a gem like ruby-debug or rdiscount. You&#8217;ll have seen an error like this: %gem install ruby-debug Building native extensions. This could take a while... ERROR: Error installing ruby-debug: ERROR: Failed to build gem native extension. [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re stuck trying to run Ruby on Windows, one barrier you might have encountered is in trying to install a gem like ruby-debug or rdiscount. You&#8217;ll have seen an error like this:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">%gem install ruby-debug
Building native extensions.  This could take a while...
ERROR:  Error installing ruby-debug:
        ERROR: Failed to build gem native extension.
&nbsp;
C:/Ruby187/bin/ruby.exe extconf.rb
creating Makefile
&nbsp;
make
'make' is not recognized as an internal or external command, operable program or batch file.
&nbsp;
&nbsp;
Gem files will remain installed in C:/Ruby187/lib/ruby/gems/1.8/gems/linecache-0.43 for inspection.
Results logged to C:/Ruby187/lib/ruby/gems/1.8/gems/linecache-0.43/ext/gem_make.out</pre>
</div></p>

<p>That&#8217;s no fun.</p>

<p>The good news is, the lovely guys at <a href="http://rubyinstaller.org/">Ruby Installer</a> have put together a fix, called the DevKit. This installs the low-level bits and pieces needed to build those pesky native extensions on your Windows machine. There are a couple of manual steps which I didn&#8217;t find especially clear, so I&#8217;m documenting them here.</p>

<ul>
<li>Download the DevKit self-extracting archive <a href="http://github.com/downloads/oneclick/rubyinstaller/DevKit-4.5.0-20100819-1536-sfx.exe">here</a></li>
<li>Run the archive, and when prompted, choose to extract it to C:\DevKit</li>
<li>When the archive has finished unpacking, open a command prompt in C:\DevKit and run
ruby dk.rb init
ruby dk.rb install</li>
<li>That&#8217;s it. You can test it using:
gem install ruby-debug</li>
</ul>

<p>Hooray!</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mattwynne.net/2010/10/12/installing-ruby-gems-with-native-extensions-on-windows/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Bring Git Joy to Windows</title>
		<link>http://blog.mattwynne.net/2008/09/13/bring-git-joy-to-windows/</link>
		<comments>http://blog.mattwynne.net/2008/09/13/bring-git-joy-to-windows/#comments</comments>
		<pubDate>Sat, 13 Sep 2008 01:21:03 +0000</pubDate>
		<dc:creator>Matt</dc:creator>
				<category><![CDATA[Agile / Lean Software Development]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[scm]]></category>
		<category><![CDATA[source control]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://blog.mattwynne.net/2008/09/13/bring-git-joy-to-windows/</guid>
		<description><![CDATA[Since moving off Windows as my development platform, git has probably been the greatest treat. A great, lightweight, self-contained and very well thought-out piece of software, it&#8217;s one of those rare tools that once you&#8217;ve used it for a while, you can&#8217;t image how you worked without it. A lot of great ruby tools are [...]]]></description>
			<content:encoded><![CDATA[<p>Since moving off Windows as my development platform, <a href="http://git.or.cz/">git</a> has probably been the greatest treat. A great, lightweight, self-contained and very well thought-out piece of software, it&#8217;s one of those rare tools that once you&#8217;ve used it for a while, you can&#8217;t image how you worked without it.</p>

<p>A lot of great ruby tools are using or moving to <a href="https://github.com/">github</a>, a platform which I&#8217;m only just starting to get my head around, but looks really exciting for the development of open-source software.</p>

<p>I suspect windows users probably feel a little excluded from git so in order to spread the love, I thought I&#8217;d have a go at installing it on a Windows machine while you just sit back and watch. Wanna play?</p>

<p><span id="more-80"></span></p>

<p>Right. Let&#8217;s start by downloading some sort of installer. I found <a href="http://code.google.com/p/msysgit/downloads/list">this</a> from a <a href="http://www.google.co.uk/search?q=git+windows+installer">google search</a>. Looks legit.</p>

<p>I run the .EXE and see the installer start up. It asks me the usual stuff about installation location, start menu shortcuts&#8230; Then I see this:</p>

<p><img src="http://blog.mattwynne.net/wp-content/uploads/2008/09/picture-1.png" alt="git installer - first page" title="git installer - first page" /></p>

<p>I don&#8217;t use any fancy command-line tools on Windows really, so I don&#8217;t mind about this stuff. I could also quite happily install it on cygwin (see <a href="http://lifehacker.com/tag/cygwin/">http://lifehacker.com/tag/cygwin/</a> for a great usage guide) but not today: I&#8217;m going to keep it nice and simple.</p>

<p>Next we see this odd poser:</p>

<p><img src="http://blog.mattwynne.net/wp-content/uploads/2008/09/picture-2.png" alt="git installer - second page" title="git installer - second page" /></p>

<p>Second option sounds a bit complicated. First one sounds warm and fuzzy.</p>

<p>And we&#8217;re off. Git goodness is pouring out onto my Windows hard-drive.</p>

<p>How about a nice cup of tea before we get into the fun stuff?</p>

<h2>Basic Version Control with Git</h2>

<p>Start by opening a command prompt. You&#8217;d better get used to this &#8211; there is a GUI but you&#8217;re definitely best off learning the tool from the prompt. Trust me, after using the command line for a few weeks, you won&#8217;t want it any other way.</p>

<p>Just type <code>git</code> and hit return. You should see the standard help text with the major commands listed. That means git is installed and we can move on.</p>

<p>Create a directory for playing around (I just made on in c:\temp) and cd into it:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\Documents and Settings\Matt&gt;cd C:\
C:\&gt;mkdir temp
C:\&gt;cd temp
C:\temp&gt;</pre>
</div></p>

<p>Now tell git to create a new source control repository in the current folder:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp&gt;git init
Initialized empty Git repository in C:/temp/.git/
&nbsp;
C:\temp&gt;</pre>
</div></p>

<p>So what git does is puts all the files it needs to run a complete version control system in that .git folder. Yep, the whole thing. No databases to set up, no web servers to run (unless you want to). By the way &#8211; the dot-prefixed name signifies, in unix-land, that this is a hidden folder. You&#8217;ll just have to learn to ignore it.</p>

<p>Let&#8217;s get an idea of what git can do by creating a text file and editing changes to it.</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp&gt;notepad hello.txt</pre>
</div></p>

<p>Type something in and save the file.</p>

<p>Now we&#8217;ll add the file to git. First of all let&#8217;s get git to wake up and take a look at what&#8217;s been going on:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp&gt;git status
# On branch master
#
# Initial commit
#
# Untracked files:
#   (use &quot;git add &amp;lt;file&gt;...&quot; to include in what will be committed)
#
#       hello.txt
nothing added to commit but untracked files present (use &quot;git add&quot; to track)</pre>
</div></p>

<p>So git knows that the file has been added to the folder, but also that it&#8217;s not currently under version control. We can add it (but not yet check in the change) like this:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp&gt;git add .</pre>
</div></p>

<p>That will add any untracked file in the current directory and below to source control.</p>

<p>Checking git status again, we&#8217;ll see that the file is now ready to be committed.</p>

<p>You have to enter a commit message, but instead of using a geeky unix command-line editor to type in your message, just use the -m flag to enter the message at the command line:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp&gt;git commit -m &quot;wrote someting really clever in the file&quot;</pre>
</div></p>

<p>Change the file once more using notepaf, and commit it again, saving a different commit message. Play around. Go nuts.</p>

<p>Now we&#8217;re going to see some of the really cool stuff git can do. Because it&#8217;s so incredibly cheap to set up a repository, and because git is built to be able to syncronise these repositories, you can set up another one, and push changes between them.</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp&gt;cd ..
C:\&gt;mkdir temp2
C:&gt;cd temp2
C:\temp2&gt;git clone C:\temp\ temp
Initialize temp/.git
Initialized empty Git repository in C:/temp2/temp/.git/
&nbsp;
C:\temp2&gt;dir
Volume in drive C has no label.
Volume Serial Number is EC69-87C6
&nbsp;
Directory of C:\temp2
&nbsp;
13/09/2008  01:11    &amp;lt;DIR&gt;          .
13/09/2008  01:11    &amp;lt;DIR&gt;          ..
13/09/2008  01:11    &amp;lt;DIR&gt;          temp
0 File(s)              0 bytes
3 Dir(s)   4,084,494,336 bytes free</pre>
</div></p>

<p>And there we have it &#8211; a freshly cloned copy of the whole repository (history and all) which we created earlier. Go on in and take a look around:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp2&gt;cd temp
&nbsp;
C:\temp2\temp&gt;dir
Volume in drive C has no label.
Volume Serial Number is EC69-87C6
&nbsp;
Directory of C:\temp2\temp
&nbsp;
13/09/2008  01:11    &amp;lt;DIR&gt;          .
13/09/2008  01:11    &amp;lt;DIR&gt;          ..
13/09/2008  01:11    &amp;lt;DIR&gt;          .git
13/09/2008  01:11                11 hello.txt
1 File(s)             11 bytes
3 Dir(s)   4,084,494,336 bytes free</pre>
</div></p>

<p>There&#8217;s a familiar face! It&#8217;s our old friend the hello.txt.</p>

<p>Try changing the file again, and checking in your changes. You&#8217;ll find you are quite safe to make changes and commit them to this new repository, stored at C:\temp2\temp</p>

<p>Now call git push. You should see this:</p>

<p><div>
<pre class="txt" style="font-family:monospace;">C:\temp2\temp&gt;git push
Counting objects: 5, done.
Writing objects: 100% (3/3), 254 bytes, done.
Total 3 (delta 0), reused 0 (delta 0)
Unpacking objects: 100% (3/3), done.
To C:\temp\/.git
2e7c420..8727e8c  master -&gt; master</pre>
</div></p>

<p>Now cd back to your original C:\temp directory, and see what&#8217;s happened to the hello.txt file. Did it change?</p>

<p>Please let me know what you think of this article. I&#8217;m having a lot of fun with git, but I appreciate that this stuff can feel intimidating to those on the outside, so I hope I&#8217;ve given you enough of a taste to want to learn more.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mattwynne.net/2008/09/13/bring-git-joy-to-windows/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>SSH on Cygwin</title>
		<link>http://blog.mattwynne.net/2007/09/29/ssh-on-cygwin/</link>
		<comments>http://blog.mattwynne.net/2007/09/29/ssh-on-cygwin/#comments</comments>
		<pubDate>Sat, 29 Sep 2007 14:33:05 +0000</pubDate>
		<dc:creator>Matt</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://blog.mattwynne.net/2007/09/29/ssh-on-cygwin/</guid>
		<description><![CDATA[I&#8217;m following Gina Trapani&#8217;s outstanding tutorials on lifehacker to get me some of that unix command-line joy on the rusty old windows box in the corner. Note to other linux-naive cygwin users out there. If you want to install the ssh command, look for the package called &#8216;openssh&#8217;. No amount of staring at the packages [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m following <a href="http://www.lifehacker.com/software/top/geek-to-live-introduction-to-cygwin-part-i-179514.php">Gina Trapani&#8217;s outstanding tutorials on lifehacker</a> to get me some of that unix command-line joy on the rusty old windows box in the corner.</p>

<p>Note to other linux-naive cygwin users out there. If you want to install the <code>ssh</code> command, look for the package called &#8216;openssh&#8217;. No amount of staring at the packages squid and ssmtp is going to make it appear where you might expect it to.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mattwynne.net/2007/09/29/ssh-on-cygwin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

