<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link rel="hub" href="http://tumblr.superfeedr.com/" xmlns:atom="http://www.w3.org/2005/Atom"/><description>Renaissance Nerd is a collection of links and articles cobbled together (and sometimes written) by Jeff Mueller.</description><title>Renaissance Nerd</title><generator>Tumblr (3.0; @renaissancenerd)</generator><link>http://renaissancenerd.net/</link><item><title>Photo Stream, Dropbox, Hazel, and Automatic Backups</title><description>&lt;p&gt;&lt;a href="http://www.macworld.com/article/1166965/quickly_share_ios_photos_with_your_mac.html"&gt;This article&lt;/a&gt; over at MacWorld gave me an idea: would it be possible to automatically back up my Photo Stream pictures to Dropbox without ever having to open iPhoto.&lt;/p&gt;

&lt;p&gt;The answer is yes; you&amp;#8217;ll need a little help from &lt;a href="http://www.noodlesoft.com/hazel.php"&gt;Hazel&lt;/a&gt; to do it, though.&lt;/p&gt;

&lt;p&gt;This rest of this article assumes that you have Dropbox and Hazel installed.&lt;/p&gt;

&lt;p&gt;Start by creating two folders in your Dropbox account, one named something like &lt;code&gt;Photo Stream&lt;/code&gt; and one named &lt;code&gt;iOS Screenshots&lt;/code&gt;. We&amp;#8217;re going to set up two rules to filter screenshots into their own folder.&lt;/p&gt;

&lt;p&gt;Next, we need to make navigating to your &lt;code&gt;Library&lt;/code&gt; folder easier, so open a new Finder window, hold down &lt;code&gt;Option&lt;/code&gt;, click the &lt;code&gt;Go&lt;/code&gt; menu at the top of the screen, and choose &lt;code&gt;Library&lt;/code&gt;. Switch to column view, then drag the Library folder to your &lt;code&gt;Favorites&lt;/code&gt; list.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m4v8hc2neR1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;Open Hazel, and click the &lt;code&gt;+&lt;/code&gt; button at the bottom of the &lt;code&gt;Folders&lt;/code&gt; list on the left. Select &lt;code&gt;Library&lt;/code&gt; from the &lt;code&gt;Favorites&lt;/code&gt; list on the left side of the file selection pane, then navigate to &lt;code&gt;Application Support&lt;/code&gt;, then &lt;code&gt;iLifeAssetManagement&lt;/code&gt;, then &lt;code&gt;assets&lt;/code&gt;, then &lt;code&gt;sub&lt;/code&gt;. Click the &lt;code&gt;Open&lt;/code&gt; button.&lt;/p&gt;

&lt;p&gt;Create a new Hazel rule called &lt;code&gt;Find subfolders&lt;/code&gt;. You only have to set one condition: &lt;code&gt;Kind&lt;/code&gt; is &lt;code&gt;Folder&lt;/code&gt;. Next, set the action to &lt;code&gt;Run rules on folder contents.&lt;/code&gt; It should look like this:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m4v8hqrT1Y1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;Next, create a rule called &lt;code&gt;Backup photos&lt;/code&gt;. This one requires two conditions: &lt;code&gt;Kind&lt;/code&gt; is &lt;code&gt;Image&lt;/code&gt;, and &lt;code&gt;Extension&lt;/code&gt; is &lt;code&gt;jpg&lt;/code&gt;. Set the action to &lt;code&gt;Copy&lt;/code&gt; to the &lt;code&gt;Photo Stream&lt;/code&gt; folder you created in your Dropbox. Click the &lt;code&gt;Options&lt;/code&gt; button, and check &lt;code&gt;Do not copy if a duplicate&lt;/code&gt;. When you&amp;#8217;re done, it should look like this:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m4v8hycpOg1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;Click &lt;code&gt;OK&lt;/code&gt; to save your rule.&lt;/p&gt;

&lt;p&gt;Finally, control-click the &lt;code&gt;Backup photos&lt;/code&gt; rule and choose &lt;code&gt;Duplicate&lt;/code&gt;. Name this new rule &lt;code&gt;Backup screenshots&lt;/code&gt;. Change the second condition to &lt;code&gt;Extension&lt;/code&gt; is &lt;code&gt;png&lt;/code&gt;, and change the action at the bottom so that the &lt;code&gt;Copy&lt;/code&gt; points to the &lt;code&gt;iOS Screenshots&lt;/code&gt; folder you created in your Dropbox. When you&amp;#8217;re done, it should look like this:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m4v8i5ukdl1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;Now, open your folders and watch as your pictures get copied over. Then, take out your iPhone or iPad and snap a picture, wait a few seconds, &lt;em&gt;et voilà&lt;/em&gt;, a copy of the picture appears in the folder and is synced to your Dropbox account.&lt;/p&gt;

&lt;p&gt;Don&amp;#8217;t forget to remove the &lt;code&gt;Library&lt;/code&gt; folder from your list of Finder favorites. You can do so by holding the &lt;code&gt;Command&lt;/code&gt; key while dragging the folder out of the list.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/24106121870</link><guid>http://renaissancenerd.net/post/24106121870</guid><pubDate>Wed, 30 May 2012 19:39:02 -0700</pubDate><category>hazel</category><category>dropbox</category><category>photostream</category><category>backup</category></item><item><title>Writing This Blog With tmux</title><description>&lt;a href="http://jeffmueller.net/blog/2012/05/19/writing-this-blog-with-tmux/"&gt;Writing This Blog With tmux&lt;/a&gt;: &lt;p&gt;Not &lt;em&gt;this blog&lt;/em&gt;. My &lt;em&gt;other blog&lt;/em&gt;. Or, I guess, my other &lt;em&gt;other&lt;/em&gt; blog. I have three now. Because I’m not busy enough. &lt;em&gt;Obviously&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;If you have any interest in using &lt;a href="http://octopress.org/"&gt;Octopress&lt;/a&gt;, this post is worth your attention.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/23402112305</link><guid>http://renaissancenerd.net/post/23402112305</guid><pubDate>Sun, 20 May 2012 00:28:46 -0700</pubDate></item><item><title>A Thought Experiment: Pixel Art</title><description>&lt;p&gt;We know we can draw a 45-pixel × 45-pixel square using an empty &lt;code&gt;div&lt;/code&gt; and some CSS.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;.square {
    background-color: #fff;
    border: 1px solid #ccc;
    height: 45px;
    width: 45px;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;And we know that we can make the square&amp;#8217;s background color red using jQuery.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$('.square').css('background-color', 'red');
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;If we take this snippet a bit further, we can alter the square&amp;#8217;s background color when it&amp;#8217;s clicked.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$('.square').click(function() {
  $(this).css('background-color', 'red');
});
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;But what if we want to turn it off again&amp;#8212;that is, what if we want the background of the square to be white if it&amp;#8217;s clicked while the background is red?&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$('.square').click(function() {
  var newBackground = ($(this).css('background-color') == 'rgb(255,255,255)') ? 'white' : 'red';
  $(this).css('background-color', newBackground);
});
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Now we can toggle the square&amp;#8217;s color like a switch. Which is &lt;em&gt;utterly useless&lt;/em&gt;. Unless you float the square, duplicate it 15 times, wrap all 16 in a row, then duplicate the row 11 times. Now we have a 16 × 12 grid of squares that can be toggled on an off. We&amp;#8217;ve created a pixel art canvas.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m45pec0fky1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;In &lt;a href="http://stuff.jeffmueller.net/prototypes/pixels/"&gt;this demo&lt;/a&gt;, I&amp;#8217;ve taken the idea beyond just the basic grid of squares that can be toggled and added a rudimentary color palette. Each palette box uses an HTML5 data attribute&amp;#8212;in this case, &lt;code&gt;data-color&lt;/code&gt;&amp;#8212;to hold the color of the box, which is set via JavaScript. Finally, using a conditional to check for the presence of on-touch handlers, I optimized the whole thing for use on the iPad, which was the ultimate goal of this experiment.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;if ('ontouchstart' in document.documentElement) {
  // Handle touch events
  ...
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;When I started out, I didn&amp;#8217;t know that &lt;code&gt;onClick&lt;/code&gt; events suffer from a delay of a couple hundred milliseconds on touchscreen devices, which causes interactions to feel very sluggish if you rely on jQuery&amp;#8217;s &lt;code&gt;click&lt;/code&gt; listeners. You can see &lt;a href="https://github.com/jeffmueller/pixels/blob/master/pixels.js"&gt;here&lt;/a&gt; how I wired up touch events in favor of click events when the page is loaded on a touch-enabled device. The JavaScript isn&amp;#8217;t pretty, but it&amp;#8217;ll suffice for a project that I spent about an hour on.&lt;/p&gt;

&lt;p&gt;There was no real purpose to this, no ultimate goal. I just had the idea in the shower and wondered if I could do a quick prototype.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/23219286900</link><guid>http://renaissancenerd.net/post/23219286900</guid><pubDate>Thu, 17 May 2012 00:42:54 -0700</pubDate><category>html</category><category>css</category><category>javascript</category></item><item><title>Mapping JSON Object Arrays With CoffeeScript</title><description>&lt;p&gt;This might be a well-known technique for some of you, but it was new to me when I stumbled onto it last week.&lt;/p&gt;

&lt;p&gt;I have a Rails app that&amp;#8217;s grabbing some JSON data via AJAX and using the resulting data to display a chart using &lt;a href="http://www.highcharts.com/"&gt;Highcharts&lt;/a&gt;. If you haven&amp;#8217;t seen it, Highcharts is a JavaScript library for displaying gorgeous, interactive graphs and charts.&lt;/p&gt;

&lt;p&gt;Without getting into the full implementation, when you create a line graph, you have to pass an array of numbers to Highcharts, like this:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;series: [{
  name: 'Tokyo',
  data: [7.0, 6.9, 9.5, 14.5, 18.2, 21.5, 25.2, 26.5, 23.3, 18.3, 13.9, 9.6]
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Suppose you get a JSON object back that contains an array of numbers called &lt;code&gt;data&lt;/code&gt;. You could just pass it in to Highcharts, right?&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;series: [{
  name: 'Tokyo',
  data: json['data']
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;&lt;strong&gt;Nope.&lt;/strong&gt; The gotcha is that the values returned in the &lt;code&gt;data&lt;/code&gt; array are actually strings, not numbers, so Highcharts will choke if you don&amp;#8217;t convert the data from strings to numbers. This is pretty easy. Iterate over the array, typecast the values, store them in a new array, right?&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;var numerical_data = []
$.each(json['data'], function(k, v) {
  numerical_data[k] = (Number) v;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;It works, but that&amp;#8217;s an ugly approach. Suppose you&amp;#8217;re drawing multiple lines, each of which requires its own array of numbers. Doing the conversion via iteration ends up looking really, really gross, and you&amp;#8217;ll likely end up duplicating a lot of code.&lt;/p&gt;

&lt;p&gt;CoffeeScript&amp;#8217;s &lt;code&gt;.map&lt;/code&gt; function to the rescue:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;series: [
  name: "Cu"
  data: json['data'].map (s) -&amp;gt; (Number) s
,
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The &lt;a href="http://coffeescriptcookbook.com/chapters/arrays/mapping-arrays"&gt;map function&lt;/a&gt; handles the processing of each item in the array for you and returns a new array with the modified values. If you&amp;#8217;re familiar with Ruby, this should look pretty familiar. It&amp;#8217;s super-clean, it sticks with the DRY principle, and it&amp;#8217;s very easy to read.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/20124734703</link><guid>http://renaissancenerd.net/post/20124734703</guid><pubDate>Thu, 29 Mar 2012 11:40:00 -0700</pubDate><category>coffeescript</category><category>JavaScript</category><category>json</category></item><item><title>Installing MacVim with homebrew and Xcode 4.3</title><description>&lt;p&gt;If you&amp;#8217;ve tried running &lt;code&gt;brew install macvim&lt;/code&gt; since upgrading to Xcode 4.3, you might have run into this error:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;    Error: No developer directory found at /Developer
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The error message is obvious; the solution isn&amp;#8217;t. Try this:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;    $&amp;gt; sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
    [enter admin password]
    $&amp;gt; brew install macvim
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;You&amp;#8217;ll only run into this if you deleted the &lt;code&gt;Developer&lt;/code&gt; directory after installing Xcode 4.3.&lt;/p&gt;

&lt;p&gt;You can find more info on &lt;a href="http://code.google.com/p/macvim/issues/detail?id=404"&gt;Google Code&lt;/a&gt;.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/18481943249</link><guid>http://renaissancenerd.net/post/18481943249</guid><pubDate>Tue, 28 Feb 2012 21:03:56 -0800</pubDate><category>macvim</category><category>homebrew</category><category>xcode</category></item><item><title>RSS Feed Changes</title><description>&lt;p&gt;Hi there. If you&amp;#8217;re an RSS subscriber (all 14 of you), please take a second to update your subscription. I was using Feedburner, but I ditched it. Here&amp;#8217;s a link to the new RSS feed:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://renaissancenerd.net/rss"&gt;&lt;a href="http://renaissancenerd.net/rss"&gt;http://renaissancenerd.net/rss&lt;/a&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thanks!&lt;/p&gt;</description><link>http://renaissancenerd.net/post/18018313591</link><guid>http://renaissancenerd.net/post/18018313591</guid><pubDate>Tue, 21 Feb 2012 10:20:30 -0800</pubDate></item><item><title>Tumblr Architecture - 15 Billion Page Views a Month and Harder to Scale than Twitter</title><description>&lt;a href="http://highscalability.com/blog/2012/2/13/tumblr-architecture-15-billion-page-views-a-month-and-harder.html"&gt;Tumblr Architecture - 15 Billion Page Views a Month and Harder to Scale than Twitter&lt;/a&gt;: &lt;p&gt;(via &lt;a href="http://highscalability.com"&gt;High Scalability&lt;/a&gt;)&lt;/p&gt;

&lt;p&gt;The amount of data Tumblr pushes around in a single day is absolutely &lt;em&gt;harrowing&lt;/em&gt;.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/17574741626</link><guid>http://renaissancenerd.net/post/17574741626</guid><pubDate>Mon, 13 Feb 2012 15:21:47 -0800</pubDate></item><item><title>Using Rake, Pow, and TextExpander for Project Templates</title><description>&lt;p&gt;TL;DR: &lt;a href="https://gist.github.com/1783425"&gt;I made a Rakefile&lt;/a&gt; to automate the creation of a project template that pulls fresh copies of either Twitter Bootstrap or the HTML5 Boilerplate from GitHub. I serve the template&amp;#8217;s HTML with Pow, and I use TextExpander fills to generate boilerplate snippets.&lt;/p&gt;

&lt;hr&gt;&lt;p&gt;Over the years, I&amp;#8217;ve put together a number of project templates, each containing its own set of default HTML, CSS, and JavaScript that I would&amp;#8212;invariably&amp;#8212;abandon. Each would start off with the best intentions, but I&amp;#8217;d fail to routinely update them. They&amp;#8217;d grow stale, my workflow would change, and I&amp;#8217;d start again.&lt;/p&gt;

&lt;p&gt;This cycle repeated itself again recently as I started to move back to Web development in my spare time. Wanting to try out some &lt;a href="http://www.alistapart.com/articles/responsive-web-design/"&gt;responsive design&lt;/a&gt; techniques, I grabbed a copy of the &lt;a href="http://html5boilerplate.com/"&gt;HTML5 Boilerplate&lt;/a&gt; project, tweaked it, added some media queries, and posted it to GitHub. I deleted the repository yesterday because I realized that keeping my template in sync with the HTML5 Boilerplate&amp;#8217;s releases would be tedious. Thinking about the problem differently, I turned to &lt;a href="http://en.wikipedia.org/wiki/Rake_(software)"&gt;Rake&lt;/a&gt;, and I&amp;#8217;m pretty happy with the results.&lt;/p&gt;

&lt;h2&gt;Workflow&lt;/h2&gt;

&lt;p&gt;These days, when I start a project, shortly after some sketching but before I even think about what back-end technology will be powering the site, I focus on building the interface using plain old HTML. My default directory structure looks like this:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lz603jNBtl1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://renaissancenerd.net/post/15549520461/standard-coffeescript-procedure"&gt;I like to use CoffeeScript with Jitter&lt;/a&gt;, so I include directories named &lt;code&gt;/coffee&lt;/code&gt; and &lt;code&gt;/js&lt;/code&gt;. Everything else is pretty straight-forward: &lt;code&gt;/css&lt;/code&gt; for CSS, &lt;code&gt;/images&lt;/code&gt; for images, and a &lt;code&gt;/resources&lt;/code&gt; directory for storing things like PSD files, icon sets, and other project-specific clutter. Finally, the &lt;code&gt;/docs&lt;/code&gt; directory is for annotated CoffeeScript documentation that&amp;#8217;s generated with &lt;a href="http://jashkenas.github.com/docco/"&gt;Docco&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I create an empty file called &lt;code&gt;application.coffee&lt;/code&gt; in the &lt;code&gt;/coffee&lt;/code&gt; directory, which ends up compiled to &lt;code&gt;application.js&lt;/code&gt; in the &lt;code&gt;/js&lt;/code&gt; directory. I also include an empty &lt;code&gt;application.css&lt;/code&gt; file in the &lt;code&gt;/css&lt;/code&gt; directory. Finally, I toss in an empty &lt;code&gt;index.html&lt;/code&gt; file.&lt;/p&gt;

&lt;p&gt;If I use a framework like the HTML5 Boilerplate project or &lt;a href="https://github.com/twitter/bootstrap"&gt;Twitter Bootstrap&lt;/a&gt;, I download the package and place the project&amp;#8217;s various assets into the appropriate directories. The HTML5 Boilerplate&amp;#8217;s &lt;code&gt;index.html&lt;/code&gt; becomes the default index file when I use that project.&lt;/p&gt;

&lt;p&gt;With all of the files in place, I initialize an empty Git repository and start cranking out code. But there&amp;#8217;s an easier way.&lt;/p&gt;

&lt;h2&gt;Rake&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://gist.github.com/1783425"&gt;This file&lt;/a&gt; handles all of the above for me by providing three command-line options.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$&amp;gt; rake newblank
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This creates the blank project directory structure and a handful of empty files as outlined in the &lt;em&gt;Workflow&lt;/em&gt; section above (complete with a Git repository).&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$&amp;gt; rake newhtml5
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This clones a copy of the HTML5 Boilerplate project, places its files in the proper directories, and creates a new Git repository.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$&amp;gt; rake newtwitter
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This clones a copy of the Twitter Bootstrap project, moves the JavaScript and image assets into the proper directories, compiles the &lt;a href="http://lesscss.org/"&gt;.less&lt;/a&gt; files into a single CSS file, runs a quick find-and-replace on the compiled CSS to change references to &lt;code&gt;../img&lt;/code&gt; into &lt;code&gt;../images&lt;/code&gt; because I&amp;#8217;m tightly wound and like to name my &lt;code&gt;images&lt;/code&gt; directory &lt;code&gt;/images&lt;/code&gt;, and creates a new Git repository.&lt;/p&gt;

&lt;p&gt;To use it, create a directory for your project and place the contents of &lt;a href="https://gist.github.com/1783425"&gt;this Gist&lt;/a&gt; into a file in that directory. Name the file &lt;code&gt;Rakefile&lt;/code&gt;. Then, &lt;code&gt;cd&lt;/code&gt; into your project&amp;#8217;s directory and run one of the above commands.&lt;/p&gt;

&lt;h2&gt;Advantages&lt;/h2&gt;

&lt;p&gt;I don&amp;#8217;t have to keep my template in sync with changes to projects I use (e.g., the HTML5 Boilerplate project). I don&amp;#8217;t have to keep a blank project template full of empty files and directories lying around that will grow stale and require maintenance. I always get the latest HTML5 Boilerplate and Bootstrap code when starting a new project. Everything&amp;#8217;s boiled down to one file that&amp;#8217;s far easier to maintain and tweak as my needs change. And if a new set of fancy boilerplate comes out, all I have to do is write a new Rake task to add it to my arsenal.&lt;/p&gt;

&lt;h2&gt;Pow&lt;/h2&gt;

&lt;p&gt;You can use &lt;a href="http://pow.cx/"&gt;Pow&lt;/a&gt; to serve the flat HTML files you create using any of the templates that are generated by this Rakefile.&lt;/p&gt;

&lt;p&gt;Create a directory for your project, and then create a &lt;code&gt;public&lt;/code&gt; directory inside your new project&amp;#8217;s directory. Place a copy of the Rakefile in the &lt;code&gt;public&lt;/code&gt; directory. It should look like this:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lz603vnpGK1qz4v9x.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;cd&lt;/code&gt; into the &lt;code&gt;public&lt;/code&gt; directory, and run one of the commands to generate the template structure. Then&amp;#8212;just like you would with any other Pow-based project&amp;#8212;create a link to your project&amp;#8217;s directory (not the &lt;code&gt;public&lt;/code&gt; directory, but the root project directory) in &lt;code&gt;~/.pow&lt;/code&gt;. For more info on using Pow, &lt;a href="http://pow.cx/manual.html"&gt;see the user&amp;#8217;s manual&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Yes, you could just open your plain old HTML files in a browser without having Pow serve them, but using Pow lets you avoid addressing your assets (images, JS, CSS) with relative paths. You won&amp;#8217;t have to go through your code and change all the relative paths to full paths once you&amp;#8217;re ready to turn your templates into production code.&lt;/p&gt;

&lt;h2&gt;TextExpander&lt;/h2&gt;

&lt;p&gt;I love &lt;a href="http://smilesoftware.com/TextExpander/"&gt;TextExpander&lt;/a&gt;, and I use it to fill a gap that&amp;#8217;s left by generating blank files with no template code in them. For example, I like my default &lt;code&gt;application.coffee&lt;/code&gt; file to include the following header:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;#      Project Name v1.0
#      (c) 2012 Company Name
#      &lt;a href="http://projecturl.com"&gt;http://projecturl.com&lt;/a&gt;

# Load the application once the DOM is ready using a `jQuery.ready` shortcut.
$ -&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This block turns into a very pretty header when I run Docco to create my documentation, and it sets the application up to work with jQuery. I created a TextExpander fill to generate this header. The fill, which is triggered when I type &lt;code&gt;coffeehead&lt;/code&gt;, prompts me to enter the project name, version, company name, and project URL. For more info on how fills work, see &lt;a href="http://vimeo.com/10125313"&gt;this video&lt;/a&gt; by the venerable &lt;a href="http://www.merlinmann.com"&gt;Merlin Mann&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I have a similar fill that creates the header for my CSS files, which looks like this:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;/*
      Project Name v1.0
      (c) 2012 Company Name
      &lt;a href="http://projecturl.com"&gt;http://projecturl.com&lt;/a&gt;
*/


/*  Header
--------------------------------------------- */
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This one&amp;#8217;s triggered when I type &lt;code&gt;csshead&lt;/code&gt;. It&amp;#8217;s very similar to the CoffeeScript header. Another fill creates CSS section breaks by prompting me for the name of the section when I type &lt;code&gt;csssec&lt;/code&gt;:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;/*  Section
--------------------------------------------- */
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;If you have TextExpander and want to try these snippets for yourself, you can download a copy of them &lt;a href="http://dl.dropbox.com/u/361274/Template_Snippets.textexpander.zip"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;Bonus: Docco&lt;/h2&gt;

&lt;p&gt;Don&amp;#8217;t delete the Rakefile when you&amp;#8217;re done generating a new project! It provides a task for creating annotated documentation for your CoffeeScript:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$&amp;gt; rake doc
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Run that command, and then check the contents of the &lt;code&gt;/docs&lt;/code&gt; directory.&lt;/p&gt;

&lt;h2&gt;Requirements&lt;/h2&gt;

&lt;p&gt;I&amp;#8217;ll be honest; I lost track of all of the software that&amp;#8217;s required to make this work. You&amp;#8217;ll need Ruby and Rake and &lt;a href="http://git-scm.com/"&gt;Git&lt;/a&gt; to get started. To compile the &lt;code&gt;.less&lt;/code&gt; files that come with the Twitter Bootstrap project, you&amp;#8217;ll need &lt;a href="http://nodejs.org/"&gt;Node.js and NPM&lt;/a&gt;. Once you have NPM installed, you&amp;#8217;ll need to &lt;a href="http://twitter.github.com/bootstrap/less.html#compiling"&gt;install the less package&lt;/a&gt;. You can also install &lt;a href="http://coffeescript.org/#installation"&gt;CoffeeScript&lt;/a&gt; and Docco with NPM; Docco also &lt;a href="http://jashkenas.github.com/docco/"&gt;recommends installing Pygments&lt;/a&gt; for syntax highlighting. If I missed any other requirements, please let me know in the comments.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/17363054042</link><guid>http://renaissancenerd.net/post/17363054042</guid><pubDate>Thu, 09 Feb 2012 22:53:00 -0800</pubDate><category>git</category><category>coffeescript</category><category>javascript</category><category>css</category><category>html</category><category>rake</category><category>docco</category><category>html5boilerplate</category><category>twitterbootstrap</category></item><item><title>Bridging the App Gap</title><description>&lt;a href="http://www.lukew.com/ff/entry.asp?1499"&gt;Bridging the App Gap&lt;/a&gt;: &lt;p&gt;&lt;a href="http://www.lukew.com"&gt;Luke Wroblewski’s&lt;/a&gt; notes from &lt;a href="http://www.marco.org"&gt;Marco Arment’s&lt;/a&gt; An Event Apart talk.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/17270504362</link><guid>http://renaissancenerd.net/post/17270504362</guid><pubDate>Wed, 08 Feb 2012 10:02:44 -0800</pubDate></item><item><title>Differences Between jQuery .bind() vs .live() vs .delegate() vs .on()</title><description>&lt;a href="http://www.elijahmanor.com/2012/02/differences-between-jquery-bind-vs-live.html"&gt;Differences Between jQuery .bind() vs .live() vs .delegate() vs .on()&lt;/a&gt;: &lt;p&gt;(via &lt;a href="http://www.elijahmanor.com"&gt;Web Dev .NET&lt;/a&gt;)&lt;/p&gt;

&lt;p&gt;If you’ve looked at jQuery’s documentation lately, you might have noticed that &lt;code&gt;.live()&lt;/code&gt; is on the chopping block and will soon be deprecated. This article’s a good guide to understanding why and what will replace it.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/17257587470</link><guid>http://renaissancenerd.net/post/17257587470</guid><pubDate>Wed, 08 Feb 2012 00:27:40 -0800</pubDate></item><item><title>Ruby Trick Shots: A Video of 24 Ruby Tips and Tricks</title><description>&lt;a href="http://rubyreloaded.com/trickshots/"&gt;Ruby Trick Shots: A Video of 24 Ruby Tips and Tricks&lt;/a&gt;: &lt;p&gt;Nice little screencast by &lt;a href="http://peterc.org/"&gt;Peter Cooper&lt;/a&gt; of &lt;a href="http://rubyshow.com/"&gt;The Ruby Show&lt;/a&gt; fame. Also, get more Ruby tricks by following @&lt;a href="http://twitter.com/#!/rubytrickshots"&gt;rubytrickshots&lt;/a&gt; on Twitter.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/17254571982</link><guid>http://renaissancenerd.net/post/17254571982</guid><pubDate>Tue, 07 Feb 2012 22:19:36 -0800</pubDate></item><item><title>(via Adventure - mlkshk)</title><description>&lt;img src="http://25.media.tumblr.com/tumblr_lyoo0qvFEb1qgecwuo1_500.png"/&gt;&lt;br/&gt;&lt;br/&gt;&lt;p&gt;(via &lt;a href="http://mlkshk.com/p/C5MJ"&gt;Adventure - mlkshk&lt;/a&gt;)&lt;/p&gt;</description><link>http://renaissancenerd.net/post/16836857863</link><guid>http://renaissancenerd.net/post/16836857863</guid><pubDate>Tue, 31 Jan 2012 14:05:13 -0800</pubDate></item><item><title>Tutorial: Rails 3.2 with Ruby 1.9.3 on Heroku</title><description>&lt;a href="http://railsapps.github.com/rails-heroku-tutorial.html"&gt;Tutorial: Rails 3.2 with Ruby 1.9.3 on Heroku&lt;/a&gt;: &lt;p&gt;This is a very thorough explanation of how to get a new Rails app running on Heroku (including how to use a custom domain). If you’re interested in doing such a thing, start here.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/16827961543</link><guid>http://renaissancenerd.net/post/16827961543</guid><pubDate>Tue, 31 Jan 2012 11:07:13 -0800</pubDate></item><item><title>A Beginners Guide to HTML &amp; CSS</title><description>&lt;a href="http://learn.shayhowe.com/html-css/terminology-syntax-intro/"&gt;A Beginners Guide to HTML &amp; CSS&lt;/a&gt;: &lt;p&gt;Just getting started with HTML and CSS? Go here.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/16827160873</link><guid>http://renaissancenerd.net/post/16827160873</guid><pubDate>Tue, 31 Jan 2012 10:46:47 -0800</pubDate></item><item><title>"Over time, software builds up legacy. The old technology is baked in, and the roots of the product..."</title><description>“Over time, software builds up legacy. The old technology is baked in, and the roots of the product are so knotted that simply unwinding them becomes a massive undertaking. Think about trying to uproot a 250-year-old oak tree versus a two-year-old one.”&lt;br/&gt;&lt;br/&gt; - &lt;em&gt;&lt;p&gt;&lt;a href="http://www.inc.com/magazine/201202/jason-fried/starting-over-get-real.html"&gt;Jason Fried&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Or, put another way:&lt;/p&gt;

&lt;p&gt;“The bones of your software are all the bad decisions you made early on ossified over time. Sometimes you have to break them to move on.” - &lt;a href="https://twitter.com/#!/urbanape/status/161840823024091136"&gt;Zachery Bir&lt;/a&gt;&lt;/p&gt;&lt;/em&gt;</description><link>http://renaissancenerd.net/post/16414345396</link><guid>http://renaissancenerd.net/post/16414345396</guid><pubDate>Tue, 24 Jan 2012 10:00:28 -0800</pubDate></item><item><title>JavaScript pattern and antipattern collection</title><description>&lt;a href="http://shichuan.github.com/javascript-patterns/"&gt;JavaScript pattern and antipattern collection&lt;/a&gt;: &lt;p&gt;Hard to believe this is free.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/16081267786</link><guid>http://renaissancenerd.net/post/16081267786</guid><pubDate>Wed, 18 Jan 2012 14:45:37 -0800</pubDate></item><item><title>Standard CoffeeScript Procedure</title><description>&lt;p&gt;Here&amp;#8217;s a quick one that I&amp;#8217;ve really started to like. I&amp;#8217;ve taken to setting up new projects with &lt;code&gt;js&lt;/code&gt; and &lt;code&gt;coffee&lt;/code&gt; directories in the root of the project. Then, I use &lt;a href="https://github.com/TrevorBurnham/Jitter"&gt;Jitter&lt;/a&gt; to watch the &lt;code&gt;coffee&lt;/code&gt; directory for changes. It automatically recompiles the JavaScript files every time I save my changes.&lt;/p&gt;

&lt;p&gt;Jitter takes two arguments: your CoffeeScript directory, and your compiled JavaScript directory, like this:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$&amp;gt; jitter coffee js
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;So, when I start working, I run that command in the root directory of the project, and Jitter goes to work.&lt;/p&gt;

&lt;p&gt;You can make it even simpler by setting up a Bash alias. Add this to your &lt;code&gt;.bashrc&lt;/code&gt; or &lt;code&gt;.bash_profile&lt;/code&gt;:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;alias jjitter='jitter coffee js'
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Now, when you start working, just enter &lt;code&gt;jjitter&lt;/code&gt;, and you&amp;#8217;re off to the races.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/15549520461</link><guid>http://renaissancenerd.net/post/15549520461</guid><pubDate>Sun, 08 Jan 2012 19:42:45 -0800</pubDate><category>bash</category><category>coffeescript</category><category>JavaScript</category></item><item><title>Profiling CSS for fun and profit. Optimization notes.</title><description>&lt;a href="http://perfectionkills.com/profiling-css-for-fun-and-profit-optimization-notes/"&gt;Profiling CSS for fun and profit. Optimization notes.&lt;/a&gt;: &lt;p&gt;(via &lt;a href="http://perfectionkills.com"&gt;Perfection Kills&lt;/a&gt;)&lt;/p&gt;

&lt;p&gt;Eye-opening and incredibly thorough. The news about &lt;code&gt;border-radius&lt;/code&gt; bums me out; I love that property.&lt;/p&gt;</description><link>http://renaissancenerd.net/post/15352379804</link><guid>http://renaissancenerd.net/post/15352379804</guid><pubDate>Thu, 05 Jan 2012 10:13:31 -0800</pubDate></item><item><title>"If I wrote a post saying “Don’t pass arguments to methods, just promote your data to a..."</title><description>“If I wrote a post saying “Don’t pass arguments to methods, just promote your data to a global” I’d be crucified. Yet we do the same thing (albeit on a smaller scale) every time we write a Rails application.”&lt;br/&gt;&lt;br/&gt; - &lt;em&gt;&lt;p&gt;&lt;a href="http://blog.steveklabnik.com/posts/2011-12-30-active-record-considered-harmful"&gt;ActiveRecord (and Rails) Considered Harmful - Literate Programming&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is something that I’ve been actively ignoring over the years, but it secretly bothered me.&lt;/p&gt;

&lt;p&gt;I’ve posted a couple of articles recently that were critical of some of the things I enjoy using, including CoffeeScript and Rails. This isn’t an attempt to troll visitors or start arguments. It’s more an attempt to encourage the 3 people who read this site to think about tools differently. Always question your tools. Hardware, software, whatever.&lt;/p&gt;&lt;/em&gt;</description><link>http://renaissancenerd.net/post/15033743448</link><guid>http://renaissancenerd.net/post/15033743448</guid><pubDate>Fri, 30 Dec 2011 09:50:25 -0800</pubDate></item><item><title>"From a front-end development perspective, the mobile first approach also requires the default CSS..."</title><description>“From a front-end development perspective, the mobile first approach also requires the default CSS rules go into the main style.css sheet and that we progressively enhance layout and further rules for larger screens using min-width: Media Queries.”&lt;br/&gt;&lt;br/&gt; - &lt;em&gt;&lt;p&gt;&lt;a href="http://blog.tommilway.com/post/14322949339/how-to-build-a-modern-website-in-2011"&gt;Tom Milway - How To Build a Modern Website in 2011&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you’ve been looking for a succinct, plain-English explanation of how responsive design works, here it is.&lt;/p&gt;&lt;/em&gt;</description><link>http://renaissancenerd.net/post/14629876183</link><guid>http://renaissancenerd.net/post/14629876183</guid><pubDate>Thu, 22 Dec 2011 12:23:44 -0800</pubDate></item></channel></rss>

