<?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"
	>

<channel>
	<title>tail -f development.log</title>
	<atom:link href="http://craigjolicoeur.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://craigjolicoeur.com</link>
	<description>code with a purpose</description>
	<pubDate>Tue, 26 Aug 2008 16:40:50 +0000</pubDate>
	<generator>http://wordpress.org/?v=abc</generator>
	<language>en</language>
			<item>
		<title>ParseHTML 1.12 Released</title>
		<link>http://craigjolicoeur.com/2008/08/parsehtml-112-released/</link>
		<comments>http://craigjolicoeur.com/2008/08/parsehtml-112-released/#comments</comments>
		<pubDate>Thu, 21 Aug 2008 16:55:10 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[code]]></category>

		<category><![CDATA[ruby]]></category>

		<category><![CDATA[HTML]]></category>

		<category><![CDATA[ParseHTML]]></category>

		<category><![CDATA[Parser]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=64</guid>
		<description><![CDATA[Version 1.12 of the ParseHTML library has been released.]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve updated the <a href="http://github.com/cpjolicoeur/parsehtml">ParseHTML code on github</a> to the latest 1.12 version.</p>
<p>I haven&#8217;t done much work with the ParseHTML library, simply because I wasn&#8217;t actively doing development on the <a href="http://github.com/cpjolicoeur/clothblue">ClothBlue HTML-to-Markdown library</a>.  ClothBlue is the reason I wrote ParseHTML in the first place.  Well, I&#8217;ve had some downtime and figured I would revive the ClothBlue rewrite effort and that meant getting ParseHTML up to snuff.</p>
<p>The library should be fully working now as most of the previously reported bugs have been sorted out.  If you find any issues or new features you want added, just let me know.</p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/08/parsehtml-112-released/feed/</wfw:commentRss>
		</item>
		<item>
		<title>My bash history</title>
		<link>http://craigjolicoeur.com/2008/08/my-bash-history/</link>
		<comments>http://craigjolicoeur.com/2008/08/my-bash-history/#comments</comments>
		<pubDate>Mon, 04 Aug 2008 01:31:08 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[code]]></category>

		<category><![CDATA[git]]></category>

		<category><![CDATA[bash]]></category>

		<category><![CDATA[history]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=60</guid>
		<description><![CDATA[Here is my recent bash history]]></description>
			<content:encoded><![CDATA[<pre class="code">
$ history 1000 | \
awk '{a[$2]++}END{for(i in a){print a[i] " " i}}' | \
sort -rn | head

123 git
80 ruby
71 gs
43 cls
20 git-wtf
18 ll
17 rake
17 gba
16 cd
12 vim
</pre>
<p>I guess you can say I took the git plunge whole-heartedly.  The gs, gba, and git-wtf commands are all git aliases or scripts (git status, git branch -a, and a git branch commit analyzer).</p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/08/my-bash-history/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Rails 2.x In Place Editor</title>
		<link>http://craigjolicoeur.com/2008/07/rails-2x-in-place-editor/</link>
		<comments>http://craigjolicoeur.com/2008/07/rails-2x-in-place-editor/#comments</comments>
		<pubDate>Thu, 31 Jul 2008 18:21:32 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[code]]></category>

		<category><![CDATA[rails]]></category>

		<category><![CDATA[in_place_editor]]></category>

		<category><![CDATA[rubyonrails]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=58</guid>
		<description><![CDATA[A few Rails 2.x gotchas when using the in_place_editor plugin]]></description>
			<content:encoded><![CDATA[<p>I had the need to use the old in_place_editor functionality in a new Rails app that I&#8217;m working on.  I hadn&#8217;t used the functionality for a while now and using it in a Rails 2.x environment is a bit different than in a Rails 1.x environment so I thought I&#8217;d share what I found.</p>
<p>The in_place_editor functionality has been completed deprecated in the Rails 2.x codebase and now you need to install <a href="http://svn.rubyonrails.org/rails/plugins/in_place_editing/README">the plugin</a> to use the functionality.  To install the plugin use the following command from your rails root directory:</p>
<pre class="code">
ruby script/plugin install http://svn.rubyonrails.org/rails/plugins/in_place_editing
</pre>
<p>Now, if you are using the new authenticity token features of Rails 2, the plugin won&#8217;t work for you out of the box.  First you will need to <a href="http://dev.rubyonrails.org/ticket/10055">apply this patch</a>.  It&#8217;s best to apply the patch even if you aren&#8217;t using the authenticity token feature just so you are &#8220;future-proof.&#8221;  I&#8217;m not sure why the plugin trunk hasn&#8217;t been updated with the patch already, but it hasn&#8217;t so you need to do it yourself.</p>
<p>Now you can use both the <code><a href="http://rails.rubyonrails.com/classes/ActionView/Helpers/JavaScriptMacrosHelper.html#M000575">in_place_editor</a></code> and <code><a href="http://rails.rubyonrails.com/classes/ActionView/Helpers/JavaScriptMacrosHelper.html#M000576">in_place_editor_field</a></code> helpers in your view files.</p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/rails-2x-in-place-editor/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Learn a (New) Programming Language</title>
		<link>http://craigjolicoeur.com/2008/07/learn-a-new-programming-language/</link>
		<comments>http://craigjolicoeur.com/2008/07/learn-a-new-programming-language/#comments</comments>
		<pubDate>Wed, 23 Jul 2008 15:45:18 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[code]]></category>

		<category><![CDATA[languages]]></category>

		<category><![CDATA[objective-c]]></category>

		<category><![CDATA[perl]]></category>

		<category><![CDATA[programming]]></category>

		<category><![CDATA[ruby]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=56</guid>
		<description><![CDATA[Which new programming language will you try to learn this year?]]></description>
			<content:encoded><![CDATA[<div style="text-align:center;" class="center"><img src="http://craigjolicoeur.com/wp-content/uploads/2008/07/learnperl.jpg" alt="learnperl.jpg" border="0" width="428" height="428" /></div>
<p>I came across <a href="http://www.michaelminella.com/blog/22.html">an article on Michael Minella&#8217;s blog</a> the other day about continually adding new tools to the programming tool box.  Specifically, Michael references on of the tenets of the <a href="http://en.wikipedia.org/wiki/Pragmatic_Programmer">Pragmatic Programmer</a> to learn at least one new programming language every year.</p>
<p>That got me thinking and challenged me to pick up another language this year.  I&#8217;ve been doing Ruby development exclusively for close to three years now and have really let my PHP level of expertise slide a bit.  Other than a bit of JavaScript and some PHP for Wordpress plugins and themes, Ruby is all of done recently.</p>
<p>The language that I really want to learn and get into is <a href="http://en.wikipedia.org/wiki/Objective-c">Objective-C</a>, mostly because I&#8217;d like to dabble a bit in Cocoa development for OS X.  It&#8217;s been quite a few years since I&#8217;ve done any kind of desktop app development and I&#8217;d like to at least stay up-to-date in that world.</p>
<p>Ultimately though, I decided to really learn <a href="http://en.wikipedia.org/wiki/Perl">Perl</a> this year.  Now, I know a bit of Perl and have written some of it in the past, but I really am not as strong with Perl as I&#8217;d like to be and I think its probably one of the best languages to really have a good grasp on.  Considering that the year is already halfway over, it helps to pick a language that I am already a bit familiar with as well.</p>
<p>So, what language(s) are you learning this year to stay sharp?</p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/learn-a-new-programming-language/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Wordpress App for iPhone</title>
		<link>http://craigjolicoeur.com/2008/07/wordpress-app-for-iphone/</link>
		<comments>http://craigjolicoeur.com/2008/07/wordpress-app-for-iphone/#comments</comments>
		<pubDate>Tue, 22 Jul 2008 19:27:59 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[wordpress]]></category>

		<category><![CDATA[iPhone]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/2008/07/wordpress-app-for-iphone/</guid>
		<description><![CDATA[The Wordpress application for the iPhone has been released. In fact, I&#8217;m making this post from my iPhone to test it out. 
Go grab it from the AppStore and give it a try.
]]></description>
			<content:encoded><![CDATA[<p>The Wordpress application for the iPhone has been released. In fact, I&#8217;m making this post from my iPhone to test it out. </p>
<p>Go grab it from the AppStore and give it a try.</p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/wordpress-app-for-iphone/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Pradipta&#8217;s Rolodex: Laughs from the Internets</title>
		<link>http://craigjolicoeur.com/2008/07/pradiptas-rolodex-laughs-from-the-internets/</link>
		<comments>http://craigjolicoeur.com/2008/07/pradiptas-rolodex-laughs-from-the-internets/#comments</comments>
		<pubDate>Fri, 18 Jul 2008 12:37:08 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[Misc]]></category>

		<category><![CDATA[humor]]></category>

		<category><![CDATA[rails]]></category>

		<category><![CDATA[recruiter]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=45</guid>
		<description><![CDATA[You have to love how a small thing can turn very big and funny on the internet.]]></description>
			<content:encoded><![CDATA[<div style="text-align:center;margin-bottom:10px;" class="centered"><img src="http://craigjolicoeur.com/wp-content/uploads/2008/07/400-rails-developers-starring-pradipta-as-max-archie.jpg" alt="400_rails_developers_starring_pradipta_as_max_archie.jpg" border="0" width="400" height="129" /></div>
<p>Late last night I was *lucky* enough to be included in a mass mailing from a *recruiter* who was looking to fill some Ruby on Rails positions.</p>
<blockquote><p>
From: Pradipta Archiputra <max@prodigussource.com></p>
<p>I have a couple of Ruby on Rails position, wanted to know if you are interested?</p>
<p>Max Archie<br />
Technical Recruiter<br />
Prodigus Source<br />
Cell: 219-669-9216<br />
Phone: 312-235-2365<br />
Max@prodigussource.com
</p></blockquote>
<p>In and of itself, this email is not unfamiliar to most of us, but the interesting (annoying) thing is that the email was sent to about 500 people all in the TO: field of the email, not via the BCC: fields.</p>
<p>Personally, I clicked the REPLY button and told Max (Pradipta) that I wasn&#8217;t interested in working with someone who couldn&#8217;t use his email client properly and to remove me from his list.  I didn&#8217;t think much else about it and went to bed for the night</p>
<p>Naturally though, it was only a matter of time before some <strike>noob</strike> person clicked REPLY TO ALL and sent the following message to all 500 recipients.</p>
<blockquote><p>
From: Zach C***** <****@******.com></p>
<p>What are the positions?
</p></blockquote>
<p>That simple REPLY TO ALL set off one of the best spontaneous email threads I have read in a long time and when I woke up this morning I had about 50 replies to read and laugh at.</p>
<p>The list started off bashing the Bangalore HR scene for creating an Epic FAIL and then morphed into a very friendly and humorous discussion where people started introducing themselves like we all had been including in some kind of special Rails developer club for a reason.  </p>
<p>Next a suggestion was raised to start a Google Group and the call when out for appropriate names. At about 1:30 AM EST, the <a href="http://groups.google.com/group/pradiptas-rolodex">Pradipta&#8217;s Rolodex group</a> was launched complete with fancy logo.</p>
<p>Fittingly, the last email on the original thread was the following:</p>
<blockquote><p>
From:  Matt S****** <********@gmail.com></p>
<p>Hi Max,</p>
<p>I am a recruiter who has an opening for a top-tier recruiter such as yourself.  I need someone who can unwittingly set off the fury of *at least* 400 people, while ignoring all basic email etiquette.  Would you be interested?   If not, do you know anyone else who is currently looking for such an opportunity?</p>
<p>Sincerely,<br />
Thanks for the mile long email thread out of freakin nowhere
</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/pradiptas-rolodex-laughs-from-the-internets/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SSH Config Aliases</title>
		<link>http://craigjolicoeur.com/2008/07/ssh-config-aliases/</link>
		<comments>http://craigjolicoeur.com/2008/07/ssh-config-aliases/#comments</comments>
		<pubDate>Wed, 16 Jul 2008 01:41:44 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[code]]></category>

		<category><![CDATA[SSH]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=42</guid>
		<description><![CDATA[How to setup aliases for to quick-connect to SSH hosts]]></description>
			<content:encoded><![CDATA[<p>If you are like me, you do quite a bit of connecting to remote servers via SSH.  Well, here is a quick timesaving hint to save you a few keystrokes.</p>
<p>Instead of having to type </p>
<pre class="code">
ssh username@hostname.com
</pre>
<p>from the command line to connect to your server each time, wouldn&#8217;t it be nicer to just type something like this</p>
<pre class="code">
ssh foo
</pre>
<p>Well, if you edit your ssh config file you can add these aliases.  You should most likely find your ssh config located in your user directory at <code>~/.ssh/config</code> . If the file doesn&#8217;t already exist, go ahead and create it.  </p>
<p>To add aliases you simply add new Host entries in the following format</p>
<pre class="code">
Host aliasname
HostName your.domain.name
User your_ssh_username
Port 1234
</pre>
<p>Just give the alias you want to use and supply your server and username credentials.  The <code>Port</code> line is optional if you are using the default SSH port (which you shouldn&#8217;t be for security reasons, but that&#8217;s beyond the scope of this post).  Once you add those entries to your config file you can simply do the following and save yourself some typing:</p>
<pre class="code">
ssh aliasname
</pre>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/ssh-config-aliases/feed/</wfw:commentRss>
		</item>
		<item>
		<title>WordPress 2.6 Released</title>
		<link>http://craigjolicoeur.com/2008/07/wordpress-26-released/</link>
		<comments>http://craigjolicoeur.com/2008/07/wordpress-26-released/#comments</comments>
		<pubDate>Tue, 15 Jul 2008 13:54:48 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=41</guid>
		<description><![CDATA[WordPress 2.6 has been officially released.]]></description>
			<content:encoded><![CDATA[<p>The latest version of WordPress has been released.  You can <a href="http://wordpress.org">download version 2.6</a> while it&#8217;s hot (or you can wait a few days until it cools off a bit if that&#8217;s your style).  I&#8217;ve been using 2.6 on a few projects for the past few weeks and it seems pretty nice.  <a href="http://wordpress.org/extend/plugins/feedcache">My FeedCache plugin</a> is already WP 2.6 ready as well.</p>
<p>Here is a quick video preview of the major enhancements in WP 2.6.</p>
<div style="text-align:center"><embed src="http://v.wordpress.com/mARhRBcT/fmt_std" class="center" type="application/x-shockwave-flash" width="400" height="250" flashvars="blog_domain=http://wordpress.org/development/2008/07/wordpress-26/&#038;width=400&#038;height=250"> </embed></div>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/wordpress-26-released/feed/</wfw:commentRss>
		</item>
		<item>
		<title>List Item Indentation in IE6</title>
		<link>http://craigjolicoeur.com/2008/07/li-indentation-in-ie6/</link>
		<comments>http://craigjolicoeur.com/2008/07/li-indentation-in-ie6/#comments</comments>
		<pubDate>Mon, 14 Jul 2008 15:39:43 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[code]]></category>

		<category><![CDATA[CSS]]></category>

		<category><![CDATA[HTML]]></category>

		<category><![CDATA[IE6]]></category>

		<category><![CDATA[LI]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=40</guid>
		<description><![CDATA[Can't figure out why your list items are indented in IE6?]]></description>
			<content:encoded><![CDATA[<p><img src="http://craigjolicoeur.com/wp-content/uploads/2008/07/trash-ie6.jpg" alt="trash-ie6.jpg" border="0" width="130" height="115" align="right" class="alignright" />I just recently came across an issue where I couldn&#8217;t figure out why my list items <code>&lt;li&gt;</code> tags where being indented in IE6.  My CSS file had the proper margins and paddings set and, naturally, it worked fine in every single other browser except IE6.  </p>
<p>Well, it turns out one simple CSS rule was causing my problem and if you are having the same issue, you might want to check if you have the &#8220;offending&#8221; rule in your CSS as well.</p>
<pre name="code" class="css">

list-style-position: inside;
</pre>
<p>Simply remove the <code>list-style-position</code> rule and the indentation behaves like you expected.</p>
<p>To those of you out there still using IE6, please, please, please <a href="http://www.savethedevelopers.org/index.php">help save the developers.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/li-indentation-in-ie6/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Ruby Iconv to the Rescue</title>
		<link>http://craigjolicoeur.com/2008/07/ruby-iconv-to-the-rescue/</link>
		<comments>http://craigjolicoeur.com/2008/07/ruby-iconv-to-the-rescue/#comments</comments>
		<pubDate>Mon, 14 Jul 2008 13:33:20 +0000</pubDate>
		<dc:creator>Craig</dc:creator>
		
		<category><![CDATA[ruby]]></category>

		<category><![CDATA[ascii]]></category>

		<category><![CDATA[iconv]]></category>

		<category><![CDATA[utf8]]></category>

		<guid isPermaLink="false">http://craigjolicoeur.com/?p=38</guid>
		<description><![CDATA[How Iconv can help convert UTF-8 characters in to ascii output.]]></description>
			<content:encoded><![CDATA[<p>I ran into a situation today while working on a client project that was resulting in some &#8220;funky&#8221; output.</p>
<p>I&#8217;ve been using <a href="http://sporkmonger.com/projects/feedtools/">Bob Aman&#8217;s standard FeedTools library</a> to grab and parse some RSS feeds for output in a WordPress site.  </p>
<div style="text-align:center;"><img src="http://craigjolicoeur.com/wp-content/uploads/2008/07/utf8-issues.jpg" alt="utf8_issues.jpg" border="0" width="450" height="156" class="center" /></div>
<p>Now, it was obvious to me this had something to do with character encoding issues so I dug in to find out the problem.  It turns out FeedTools converts the feeds it parses to <a href="http://en.wikipedia.org/wiki/UTF-8">UTF-8</a> encoding, which is great, but can result in some strange characters in the string depending on what the original feed encoding was.</p>
<p>Viewing the native feeds in a feed reader I could see they were simply quotes, apostrophes and ellipses characters.  I needed a way to either convert these character strings into <a href="http://en.wikipedia.org/wiki/ASCII">ASCII</a> printable characters or simply discard them altogether. </p>
<p>I didn&#8217;t want to go through the process of setting up a translation table for every possible character code that might possibly show up in a feed title, so I simply chose to discard the &#8220;unprintable&#8221; strings completely.  I came across <a href="http://www.jroller.com/obie/tags/unicode">this post by Obie Fernandez</a> and decided his simple method would work for me.</p>
<pre name="code" class="ruby">

require &#039;iconv&#039;

class String
  def to_ascii_iconv
    converter = Iconv.new(&#039;ASCII//IGNORE//TRANSLIT&#039;, &#039;UTF-8&#039;)
    converter.iconv(self).unpack(&#039;U*&#039;).select{ |cp| cp &lt; 127 }.pack(&#039;U*&#039;)
  end
end
</pre>
<p><a href="http://www.ruby-doc.org/stdlib/libdoc/iconv/rdoc/index.html">Ruby&#8217;s built-in Iconv library</a> can be used for charset conversions.  I extended the <code>String</code> class to include a new <code>to_ascii_iconv</code> method.  This method creates a new Iconv converter that will convert from UTF-8 encoding to ASCII encoding.  The <code>IGNORE</code> and <code>TRANSLIT</code> flags tell the converter to ignore errors and transliterate accented chracters to an appropriate charcter in the ASCII charset.  Next, I use the newly created converter to do the conversion and then strip out any characters with decimal values higher than 127 (non-ASCII printable characters).</p>
<p>The results are exactly what I needed.  No &#8220;funky&#8221; characters in my output.</p>
]]></content:encoded>
			<wfw:commentRss>http://craigjolicoeur.com/2008/07/ruby-iconv-to-the-rescue/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>

<!-- Dynamic Page Served (once) in -0.002 seconds -->
<!-- Cached page served by WP-Cache -->
