<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/rss2full.xsl" type="text/xsl" media="screen"?><?xml-stylesheet href="http://feeds.feedburner.com/~d/styles/itemcontent.css" type="text/css" media="screen"?><rss 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" version="2.0">

<channel>
	<title>Up North</title>
	
	<link>http://micke.hallendal.net/blog</link>
	<description>Personal blog of Mikael Hallendal</description>
	<pubDate>Fri, 18 Jul 2008 14:04:09 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/UpNorth" type="application/rss+xml" /><item>
		<title>Oringen 2008</title>
		<link>http://micke.hallendal.net/blog/oringen-2008/</link>
		<comments>http://micke.hallendal.net/blog/oringen-2008/#comments</comments>
		<pubDate>Fri, 18 Jul 2008 14:04:09 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Life]]></category>

		<category><![CDATA[orienteering]]></category>

		<category><![CDATA[oringen]]></category>

		<category><![CDATA[vacation]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=293</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/oringen-2008/&t=Oringen 2008&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Going on vacation tomorrow for a week of orienteering in Sälen, Sweden. The terrain will vary from a more classic swedish orienteering for the first two stages and the go over to an alpine terrain with more open areas and higher altitude differences for the third and fourth stage. The last stage seems to be back to more classic terrain again with a mix of small hills and marshes.</p>
<p>In total the event (in my class) will be about 30km as the birds fly which should translate into something like 45-50km of terrain running over the course of five days. Hopefully I&#8217;ve exercised enough, I&#8217;ve tried to do 4-5 sessions per week over the last couple of weeks and luckily Guadec had little impact on the overall fitness as this week felt really good.</p>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/oringen-2008/&t=Oringen 2008&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Going on vacation tomorrow for a week of orienteering in Sälen, Sweden. The terrain will vary from a more classic swedish orienteering for the first two stages and the go over to an alpine terrain with more open areas and higher altitude differences for the third and fourth stage. The last stage seems to be back to more classic terrain again with a mix of small hills and marshes.</p>
<p>In total the event (in my class) will be about 30km as the birds fly which should translate into something like 45-50km of terrain running over the course of five days. Hopefully I&#8217;ve exercised enough, I&#8217;ve tried to do 4-5 sessions per week over the last couple of weeks and luckily Guadec had little impact on the overall fitness as this week felt really good.</p>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=293&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_293"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/oringen-2008/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Back from Guadec</title>
		<link>http://micke.hallendal.net/blog/back-from-guadec/</link>
		<comments>http://micke.hallendal.net/blog/back-from-guadec/#comments</comments>
		<pubDate>Tue, 15 Jul 2008 23:18:45 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Community]]></category>

		<category><![CDATA[Programming]]></category>

		<category><![CDATA[gtk+]]></category>

		<category><![CDATA[guadec]]></category>

		<category><![CDATA[istanbul]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=292</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/back-from-guadec/&t=Back from Guadec&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Somewhat back to normal routines after a week in beautiful Istanbul. As people reading Planet GNOME have seen from others, it was a great Guadec this year.</p>
<p>I found the schedule to be a bit uninspiring but that left more time for discussions and hacking. Among the sessions I went to I really enjoyed going to <a href="http://www.atoker.com/blog/">Alp&#8217;s</a> session about Webkit and <a href="http://www.0xdeadbeef.com/weblog/">Blizzards</a> on Mozilla. Some really interesting things coming from these projects.</p>
<p><a href="http://inverted-tree.livejournal.com/">Kris</a> did a great job wrapping up the current state in GTK+ during his now traditional <a href="http://people.imendio.com/kris/gtk-state-of-the-union-2008.pdf">&#8216;GTK+ State of the Union&#8217;</a> talk and happy to see that the discussion around future GTK+ is getting started throughout the community. I spent a lot of time this year talking and listening to peoples feedback on the proposed plans. Realized that some things have been a bit left out from the discussions after the hackfest and that we need to do a better job at communicating what we plan to work on besides the cleanups and enabling of future development.</p>
<p>Finally a warm welcome to Stormy as executive director of the GNOME Foundation Board.</p>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/back-from-guadec/&t=Back from Guadec&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Somewhat back to normal routines after a week in beautiful Istanbul. As people reading Planet GNOME have seen from others, it was a great Guadec this year.</p>
<p>I found the schedule to be a bit uninspiring but that left more time for discussions and hacking. Among the sessions I went to I really enjoyed going to <a href="http://www.atoker.com/blog/">Alp&#8217;s</a> session about Webkit and <a href="http://www.0xdeadbeef.com/weblog/">Blizzards</a> on Mozilla. Some really interesting things coming from these projects.</p>
<p><a href="http://inverted-tree.livejournal.com/">Kris</a> did a great job wrapping up the current state in GTK+ during his now traditional <a href="http://people.imendio.com/kris/gtk-state-of-the-union-2008.pdf">&#8216;GTK+ State of the Union&#8217;</a> talk and happy to see that the discussion around future GTK+ is getting started throughout the community. I spent a lot of time this year talking and listening to peoples feedback on the proposed plans. Realized that some things have been a bit left out from the discussions after the hackfest and that we need to do a better job at communicating what we plan to work on besides the cleanups and enabling of future development.</p>
<p>Finally a warm welcome to Stormy as executive director of the GNOME Foundation Board.</p>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=292&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_292"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/back-from-guadec/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Heading to Guadec</title>
		<link>http://micke.hallendal.net/blog/heading-to-guadec/</link>
		<comments>http://micke.hallendal.net/blog/heading-to-guadec/#comments</comments>
		<pubDate>Sat, 05 Jul 2008 22:14:53 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Community]]></category>

		<category><![CDATA[Imendio]]></category>

		<category><![CDATA[guadec]]></category>

		<category><![CDATA[istanbul]]></category>

		<category><![CDATA[turkey]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=291</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/heading-to-guadec/&t=Heading to Guadec&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Posting this just before going to bed for an early rise to fly to Guadec in Istanbul. Unless someone gets sick last minute the entire Imendio crew will be arriving tomorrow and staying at the <a href="http://www.goldenhornhotel.com/eng/index.php">Golden Horn Sultanahmet</a>.</p>
<p>See you all there!</p>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/heading-to-guadec/&t=Heading to Guadec&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Posting this just before going to bed for an early rise to fly to Guadec in Istanbul. Unless someone gets sick last minute the entire Imendio crew will be arriving tomorrow and staying at the <a href="http://www.goldenhornhotel.com/eng/index.php">Golden Horn Sultanahmet</a>.</p>
<p>See you all there!</p>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=291&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_291"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/heading-to-guadec/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Removing a remote branch in Git</title>
		<link>http://micke.hallendal.net/blog/removing-a-remote-branch-in-git/</link>
		<comments>http://micke.hallendal.net/blog/removing-a-remote-branch-in-git/#comments</comments>
		<pubDate>Sat, 21 Jun 2008 15:27:49 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Tips]]></category>

		<category><![CDATA[git]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=290</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/removing-a-remote-branch-in-git/&t=Removing a remote branch in Git&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>This is something I&#8217;ve had to checkup a few times so I figured it would be useful both for myself and for others to keep around in a blog post.</p>
<p>To remove a remote branch you created in Git just push to it like:</p>
<pre name="code" class="shell">$ git push origin :name-of-branch</pre>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/removing-a-remote-branch-in-git/&t=Removing a remote branch in Git&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>This is something I&#8217;ve had to checkup a few times so I figured it would be useful both for myself and for others to keep around in a blog post.</p>
<p>To remove a remote branch you created in Git just push to it like:</p>
<pre name="code" class="shell">$ git push origin :name-of-branch</pre>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=290&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_290"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/removing-a-remote-branch-in-git/feed/</wfw:commentRss>
		</item>
		<item>
		<title>AsyncRunner for Ruby/GLib</title>
		<link>http://micke.hallendal.net/blog/asyncrunner-for-rubyglib/</link>
		<comments>http://micke.hallendal.net/blog/asyncrunner-for-rubyglib/#comments</comments>
		<pubDate>Wed, 04 Jun 2008 20:48:52 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Tips]]></category>

		<category><![CDATA[asynchronous]]></category>

		<category><![CDATA[glib]]></category>

		<category><![CDATA[hacking]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[threading]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=289</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/asyncrunner-for-rubyglib/&t=AsyncRunner for Ruby/GLib&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Was playing around a bit with a synchronous network library that I wanted to use from a GTK+ frontend. Obviously this wouldn&#8217;t work too well as the UI would be blocked while waiting for the library to return from it&#8217;s network calls. So I wanted to run the network operations in the background using a thread but still get the callbacks in the main thread to be able to update the UI from there.</p>
<p>I ended up writing a small class I called <a href="http://pastie.caboo.se/208925">AsyncRunner</a> which is a small proxy to call methods in a various thread and get the callback in the main thread. It&#8217;s using the GLib Mainloop so it would only be useful in the cases where you actually have one.</p>
<pre name="code" class="ruby">require 'thread-sync'
class MySyncClass
  def foo_method(arg)
  end

  def bar_method(arg1, arg2)
  end
end

sync = MySyncClass.new

# In order to get the methods of MySyncClass asynchronous it is wrapped in an AsyncRunner.
async = AsyncRunner.new(sync)

async.foo_method('test') do
  ui_update()
end

main_loop = GLib::MainLoop.new
main_loop.run</pre>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/asyncrunner-for-rubyglib/&t=AsyncRunner for Ruby/GLib&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Was playing around a bit with a synchronous network library that I wanted to use from a GTK+ frontend. Obviously this wouldn&#8217;t work too well as the UI would be blocked while waiting for the library to return from it&#8217;s network calls. So I wanted to run the network operations in the background using a thread but still get the callbacks in the main thread to be able to update the UI from there.</p>
<p>I ended up writing a small class I called <a href="http://pastie.caboo.se/208925">AsyncRunner</a> which is a small proxy to call methods in a various thread and get the callback in the main thread. It&#8217;s using the GLib Mainloop so it would only be useful in the cases where you actually have one.</p>
<pre name="code" class="ruby">require 'thread-sync'
class MySyncClass
  def foo_method(arg)
  end

  def bar_method(arg1, arg2)
  end
end

sync = MySyncClass.new

# In order to get the methods of MySyncClass asynchronous it is wrapped in an AsyncRunner.
async = AsyncRunner.new(sync)

async.foo_method('test') do
  ui_update()
end

main_loop = GLib::MainLoop.new
main_loop.run</pre>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=289&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_289"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/asyncrunner-for-rubyglib/feed/</wfw:commentRss>
		</item>
		<item>
		<title>More Ruby/Git Greatness</title>
		<link>http://micke.hallendal.net/blog/more-rubygit-greatness/</link>
		<comments>http://micke.hallendal.net/blog/more-rubygit-greatness/#comments</comments>
		<pubDate>Sun, 01 Jun 2008 09:02:28 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=288</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/more-rubygit-greatness/&t=More Ruby/Git Greatness&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>I&#8217;m really excited to see how well the Ruby (on Rails) community have received Git. A big reason is probably the awesome service <a href="http://www.github.com/">GitHub</a> but there are several other goodies coming out from the Rubyists. </p>
<p>Yesterday I blogged about the <a href="http://www.gitcasts.com/">GitCasts</a> and today I learned about <a href="http://rubyforge.org/projects/gitjour">Gitjour</a>. It&#8217;s a tool to announce and make available repositories over Bonjour so that you can list and clone repositories available on the local network.</p>
<p>To serve a repository simply call:</p>
<pre name="code" class="shell">$ gitjour serve
Registered gringo.  Starting service.</pre>
<p>You can then list and clone it with:</p>
<pre name="code" class="shell">$ gitjour list
Gathering for up to 5 seconds...
=== gringo on Tabasco.local. ===
  gitjour clone gringo</pre>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/more-rubygit-greatness/&t=More Ruby/Git Greatness&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>I&#8217;m really excited to see how well the Ruby (on Rails) community have received Git. A big reason is probably the awesome service <a href="http://www.github.com/">GitHub</a> but there are several other goodies coming out from the Rubyists. </p>
<p>Yesterday I blogged about the <a href="http://www.gitcasts.com/">GitCasts</a> and today I learned about <a href="http://rubyforge.org/projects/gitjour">Gitjour</a>. It&#8217;s a tool to announce and make available repositories over Bonjour so that you can list and clone repositories available on the local network.</p>
<p>To serve a repository simply call:</p>
<pre name="code" class="shell">$ gitjour serve
Registered gringo.  Starting service.</pre>
<p>You can then list and clone it with:</p>
<pre name="code" class="shell">$ gitjour list
Gathering for up to 5 seconds...
=== gringo on Tabasco.local. ===
  gitjour clone gringo</pre>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=288&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_288"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/more-rubygit-greatness/feed/</wfw:commentRss>
		</item>
		<item>
		<title>GitCasts — Screencasts about using Git</title>
		<link>http://micke.hallendal.net/blog/gitcasts-screencasts-about-using-git/</link>
		<comments>http://micke.hallendal.net/blog/gitcasts-screencasts-about-using-git/#comments</comments>
		<pubDate>Sat, 31 May 2008 21:55:45 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Software]]></category>

		<category><![CDATA[git]]></category>

		<category><![CDATA[screencast]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=287</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/gitcasts-screencasts-about-using-git/&t=GitCasts &#8212; Screencasts about using Git&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Stumbled over the site GitCasts which publishes regular screencasts about using Git. Should be worth a look for anyone who which to learn more about Git.</p>
<p><a href="http://www.gitcasts.com/">http://www.gitcasts.com/</a></p>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/gitcasts-screencasts-about-using-git/&t=GitCasts &#8212; Screencasts about using Git&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Stumbled over the site GitCasts which publishes regular screencasts about using Git. Should be worth a look for anyone who which to learn more about Git.</p>
<p><a href="http://www.gitcasts.com/">http://www.gitcasts.com/</a></p>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=287&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_287"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/gitcasts-screencasts-about-using-git/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Using Twitter4R on Mac OS X</title>
		<link>http://micke.hallendal.net/blog/using-twitter4r-on-mac-os-x/</link>
		<comments>http://micke.hallendal.net/blog/using-twitter4r-on-mac-os-x/#comments</comments>
		<pubDate>Fri, 30 May 2008 22:02:51 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Tips]]></category>

		<category><![CDATA[error]]></category>

		<category><![CDATA[mac_os_x]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[twitter]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/?p=286</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/using-twitter4r-on-mac-os-x/&t=Using Twitter4R on Mac OS X&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Was playing around a bit with the <a href="http://twitter4r.rubyforge.org/">Twitter4R</a> library the other day and realized that in order to make it to work on Mac OS X (Leopard) you need to also require &#8216;time&#8217;. Or you will get an error similar to <tt>lib/twitter/model.rb:268:in `init&#8217;: undefined method `parse&#8217; for Time:Class (NoMethodError)</tt>.</p>
<p>A small snippet to display my public tweets:</p>
<pre name="code" class="ruby">require 'rubygems'
gem('twitter4r', '0.3.0')
require 'twitter'

# Required on Mac OS X Leopard
require 'time'

twitter = Twitter::Client.new

hallski_timeline = twitter.timeline_for(:user, :id => 'hallski')

hallski_timeline.each do |status|
  puts status.text
end</pre>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/using-twitter4r-on-mac-os-x/&t=Using Twitter4R on Mac OS X&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Was playing around a bit with the <a href="http://twitter4r.rubyforge.org/">Twitter4R</a> library the other day and realized that in order to make it to work on Mac OS X (Leopard) you need to also require &#8216;time&#8217;. Or you will get an error similar to <tt>lib/twitter/model.rb:268:in `init&#8217;: undefined method `parse&#8217; for Time:Class (NoMethodError)</tt>.</p>
<p>A small snippet to display my public tweets:</p>
<pre name="code" class="ruby">require 'rubygems'
gem('twitter4r', '0.3.0')
require 'twitter'

# Required on Mac OS X Leopard
require 'time'

twitter = Twitter::Client.new

hallski_timeline = twitter.timeline_for(:user, :id => 'hallski')

hallski_timeline.each do |status|
  puts status.text
end</pre>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=286&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_286"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/using-twitter4r-on-mac-os-x/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Ruby bindings for Loudmouth</title>
		<link>http://micke.hallendal.net/blog/ruby-bindings-for-loudmouth/</link>
		<comments>http://micke.hallendal.net/blog/ruby-bindings-for-loudmouth/#comments</comments>
		<pubDate>Wed, 16 Apr 2008 18:26:35 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[announcement]]></category>

		<category><![CDATA[loudmouth]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[snippet]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/ruby-bindings-for-loudmouth/</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/ruby-bindings-for-loudmouth/&t=Ruby bindings for Loudmouth&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Last week I sat down and wrote bindings for Loudmouth. This means that anyone who want to write an XMPP enabled application with GTK+/Ruby now have an asynchronous library that integrates perfectly with the GLib mainloop.</p>
<p>It also gives me access to testing and writing small scripts using Loudmouth with the beauty of Ruby.</p>
<p>Here is a small example showing the bindings in the current state:</p>
<pre name="code" class="ruby">require 'loudmouth'

conn = LM::Connection.new
conn.jid = 'myjid@mydomain.com'

conn.open do |open_result|
  if open_result
    conn.authenticate('username', 'password', 'resource') do |auth_result|
      if result
         puts "Authenticated, do your stuff"
       end
    end
  end
end

GLib::MainLoop.new.run</pre>
<p>So far I have only bound the asynchronous calls and I am not sure whether I will bind synchronous ones in the future.</p>
<p>If you want to try them out or even better, help out by improving them or write example code. Create an account at <a href="http://www.github.com/">Github</a> and watch/clone the repository. It&#8217;s named <a href="http://github.com/hallski/loudmouth-ruby/tree/master">loudmouth-ruby</a>.</p>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/ruby-bindings-for-loudmouth/&t=Ruby bindings for Loudmouth&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>Last week I sat down and wrote bindings for Loudmouth. This means that anyone who want to write an XMPP enabled application with GTK+/Ruby now have an asynchronous library that integrates perfectly with the GLib mainloop.</p>
<p>It also gives me access to testing and writing small scripts using Loudmouth with the beauty of Ruby.</p>
<p>Here is a small example showing the bindings in the current state:</p>
<pre name="code" class="ruby">require 'loudmouth'

conn = LM::Connection.new
conn.jid = 'myjid@mydomain.com'

conn.open do |open_result|
  if open_result
    conn.authenticate('username', 'password', 'resource') do |auth_result|
      if result
         puts "Authenticated, do your stuff"
       end
    end
  end
end

GLib::MainLoop.new.run</pre>
<p>So far I have only bound the asynchronous calls and I am not sure whether I will bind synchronous ones in the future.</p>
<p>If you want to try them out or even better, help out by improving them or write example code. Create an account at <a href="http://www.github.com/">Github</a> and watch/clone the repository. It&#8217;s named <a href="http://github.com/hallski/loudmouth-ruby/tree/master">loudmouth-ruby</a>.</p>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=285&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_285"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/ruby-bindings-for-loudmouth/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Type registering your own widgets in Ruby/GTK+</title>
		<link>http://micke.hallendal.net/blog/type-registering-your-own-widgets-in-rubygtk/</link>
		<comments>http://micke.hallendal.net/blog/type-registering-your-own-widgets-in-rubygtk/#comments</comments>
		<pubDate>Wed, 16 Apr 2008 18:03:56 +0000</pubDate>
		<dc:creator>Mikael Hallendal</dc:creator>
		
		<category><![CDATA[Programming]]></category>

		<category><![CDATA[Tips]]></category>

		<category><![CDATA[gtk+]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[subclassing]]></category>

		<guid isPermaLink="false">http://micke.hallendal.net/blog/type-registering-your-own-widgets-in-rubygtk/</guid>
		<description><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/type-registering-your-own-widgets-in-rubygtk/&t=Type registering your own widgets in Ruby/GTK+&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>I ran into a slight problem when I tried to create a type registered subclass in Ruby/GTK+. This is done by adding <tt>type_register</tt> in your class definition. This worked fine until I tried to pass arguments to the super class constructor through the <tt>super()</tt> call. </p>
<p>In my <a href="http://micke.hallendal.net/blog/subclassing-in-rubygtk/">previous example</a>, I passed the arguments like usual to the super call. It turns out that when you have registered your class with the GObject type system (which I didn&#8217;t do in that example) it overloads the <tt>super()</tt> call and you need to pass the arguments as a hash instead.</p>
<p>Here is an example subclassing <tt>Gtk::Button</tt> that sets the button up defaulting to underline mnemonics.</p>
<pre name="code" class="ruby">require 'gtk2'

class MyButton < Gtk::Button
  type_register

  def initialize(label)
    super({:label => label, :use_underline => true})
  end

  def signal_do_clicked(*args)
    puts &#8220;Clicked&#8221;
  end
end

w = Gtk::Window.new

b = MyButton.new(&#8221;My _Button&#8221;)
w.add(b)

w.signal_connect(:delete_event) do
  Gtk.main_quit
end

w.show_all
Gtk.main</pre>
<p>Kudos to Kou for showing how to do it.</p>
Share This
]]></description>
			<content:encoded><![CDATA[<div class="diggthisplugin" style="float: right; width: 42px; padding-right: 10px; margin-left: 10px; margin-bottom: 0px;"><iframe src="http://digg.com/tools/diggthis.php?u=http://micke.hallendal.net/blog/type-registering-your-own-widgets-in-rubygtk/&t=Type registering your own widgets in Ruby/GTK+&k=#FFFFFF" scrolling="no" style="border: none; height: 80px; width: 52px;"></iframe>
		</div><p>I ran into a slight problem when I tried to create a type registered subclass in Ruby/GTK+. This is done by adding <tt>type_register</tt> in your class definition. This worked fine until I tried to pass arguments to the super class constructor through the <tt>super()</tt> call. </p>
<p>In my <a href="http://micke.hallendal.net/blog/subclassing-in-rubygtk/">previous example</a>, I passed the arguments like usual to the super call. It turns out that when you have registered your class with the GObject type system (which I didn&#8217;t do in that example) it overloads the <tt>super()</tt> call and you need to pass the arguments as a hash instead.</p>
<p>Here is an example subclassing <tt>Gtk::Button</tt> that sets the button up defaulting to underline mnemonics.</p>
<pre name="code" class="ruby">require 'gtk2'

class MyButton < Gtk::Button
  type_register

  def initialize(label)
    super({:label => label, :use_underline => true})
  end

  def signal_do_clicked(*args)
    puts &#8220;Clicked&#8221;
  end
end

w = Gtk::Window.new

b = MyButton.new(&#8221;My _Button&#8221;)
w.add(b)

w.signal_connect(:delete_event) do
  Gtk.main_quit
end

w.show_all
Gtk.main</pre>
<p>Kudos to Kou for showing how to do it.</p>
<span class="akst_link"><a href="http://micke.hallendal.net/blog/?p=284&amp;akst_action=share-this"  title="E-mail this, post to del.icio.us, etc." id="akst_link_284"  class="akst_share_link">Share This</a>
</span>]]></content:encoded>
			<wfw:commentRss>http://micke.hallendal.net/blog/type-registering-your-own-widgets-in-rubygtk/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
