<?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>Wyatt Baldwin &#187; Wyatt</title>
	<atom:link href="http://wyattbaldwin.com/author/admin/feed/" rel="self" type="application/rss+xml" />
	<link>http://wyattbaldwin.com</link>
	<description></description>
	<lastBuildDate>Tue, 20 Jul 2010 17:43:25 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>What I Learned from the apache.org Break-in</title>
		<link>http://wyattbaldwin.com/2010/04/14/what-i-learned-from-the-apache-org-break-in/</link>
		<comments>http://wyattbaldwin.com/2010/04/14/what-i-learned-from-the-apache-org-break-in/#comments</comments>
		<pubDate>Wed, 14 Apr 2010 17:01:31 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=409</guid>
		<description><![CDATA[Here&#8217;s my initial take-away after reading about the recent apache.org XSS-initiated break-in: If you&#8217;re going to allow caching of credentials (Subversion or otherwise) on a server, don&#8217;t use an account that shares credentials with any superuser account. Personally, I can&#8217;t &#8230; <a href="http://wyattbaldwin.com/2010/04/14/what-i-learned-from-the-apache-org-break-in/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s my initial take-away after reading about the recent apache.org XSS-initiated break-in:</p>
<ul>
<li>If you&#8217;re going to allow caching of credentials (Subversion or otherwise) on a server, don&#8217;t use an account that shares credentials with any superuser account. Personally, I can&#8217;t think of a good reason for these credentials to be cached in the first place (except on a development machine). As an aside, by default, Mercurial doesn&#8217;t do this; I suppose the fact that every &#8216;svn commit&#8217; is also a push makes this more &#8220;necessary&#8221; with Subversion.</li>
<li>If you have an organization-wide login (say a Windows login that is automatically sync&#8217;ed with Subversion, your enterprise RDBMS, and who knows what else[1]), <span style="text-decoration: line-through;">if at all possible</span> use a different  password on any server where you&#8217;ve got superuser access.</li>
<li>All superuser accounts on servers should have different passwords; at a minimum, if you use a common password for superuser accounts across servers, don&#8217;t use this password for other accounts.</li>
<li>Use Trac instead of Jira. [2]</li>
</ul>
<p>That&#8217;s a bare minimum; I&#8217;m still thinking about how vulnerable the organization I work for might be. Most of this probably seems obvious, but I&#8217;m betting that these and other less-than-best practices are extremely common.</p>
<p>&#8211;</p>
<p>Ref: <a title="Official Apache blog post about break-in" href="https://blogs.apache.org/infra/entry/apache_org_04_09_2010">https://blogs.apache.org/infra/entry/apache_org_04_09_2010</a></p>
<p>[1] This is a purely hypothetical scenario. <img src='http://wyattbaldwin.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>[2] Just kidding?</p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2010/04/14/what-i-learned-from-the-apache-org-break-in/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My Paste Pony</title>
		<link>http://wyattbaldwin.com/2009/09/03/my-paste-pony/</link>
		<comments>http://wyattbaldwin.com/2009/09/03/my-paste-pony/#comments</comments>
		<pubDate>Thu, 03 Sep 2009 20:49:34 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=342</guid>
		<description><![CDATA[OK, so it&#8217;s actually a unicorn, but pony sounds better in the post title. Made in Gimp by tracing over the Paste ASCII Unicorn. Silly but fun. To see the ASCII original: $ easy_install Paste &#62;&#62;&#62; import paste.pony &#62;&#62;&#62; print &#8230; <a href="http://wyattbaldwin.com/2009/09/03/my-paste-pony/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><img class="alignnone size-medium wp-image-343" title="my-paste-unicorn" src="http://wyattbaldwin.com/wp-content/uploads/2009/09/my-paste-unicorn-206x300.png" alt="my-paste-unicorn" width="206" height="300" /></p>
<p>OK, so it&#8217;s actually a unicorn, but pony sounds better in the post title. Made in Gimp by tracing over the Paste ASCII Unicorn. Silly but fun. To see the ASCII original:</p>
<p><code>$ easy_install Paste<br />
&gt;&gt;&gt; import paste.pony<br />
&gt;&gt;&gt; print paste.pony.UNICORN.decode('base64').decode('zlib')<br />
</code></p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2009/09/03/my-paste-pony/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Eclipse for Python Web Development on Ubuntu</title>
		<link>http://wyattbaldwin.com/2009/06/29/eclipse-for-python-web-development-on-ubuntu/</link>
		<comments>http://wyattbaldwin.com/2009/06/29/eclipse-for-python-web-development-on-ubuntu/#comments</comments>
		<pubDate>Mon, 29 Jun 2009 19:52:07 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=308</guid>
		<description><![CDATA[Updated 14 July 2009 for Eclipse 3.5. Now using Aptana to install PyDev. Updated 5 March 2010 for Eclipse 3.5.2 and Subversion 1.6. Updated 20 July 2010 for Eclipse 3.6 Overview So, I think I&#8217;ve finally decided that I prefer &#8230; <a href="http://wyattbaldwin.com/2009/06/29/eclipse-for-python-web-development-on-ubuntu/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><em>Updated 14 July 2009 for Eclipse 3.5. Now using Aptana to install PyDev.</em></p>
<p><em>Updated 5 March 2010 for Eclipse 3.5.2 and Subversion 1.6.</em></p>
<p><em>Updated 20 July 2010 for Eclipse 3.6<br />
</em></p>
<p><strong>Overview</strong></p>
<p>So, I think I&#8217;ve finally decided that I prefer Eclipse for Python Web development over NetBeans. (I prefer Wing IDE over both for straight Python development, but that&#8217;s another post.) Eclipse&#8217;s Python support, via PyDev, seems more advanced and NetBeans has some annoying issues. Eclipse also seems a bit snappier, at least on my machine (YMMV, blah blah).</p>
<p>Eclipse takes a bit more effort to set up, but once you&#8217;ve done it a couple times, it&#8217;s pretty straightforward. The hard part is keeping track of the links to the Eclipse update sites and remembering a few odd bits of configuration. This document gives details on installing Eclipse for Python Web development with Aptana, PyDev, and Subclipse.</p>
<p>The instructions here are Linux/Ubuntu-centric, but the instructions for getting to the Platform Binary&#8211;the smallest possible Eclipse download, as far as I can tell&#8211;are applicable to all platforms.</p>
<p><strong>Download Eclipse</strong></p>
<p>If you go to the Eclipse downloads page, you&#8217;ll see packages for Java and C++ along with some other options. If you&#8217;re doing ONLY Python development, you might wonder which version to download. These versions install cruft I don&#8217;t want or need. I finally found what I think is the smallest possible Eclipse package, the so-called Platform Runtime Library.</p>
<ul>
<li>Start here: <a title="Eclipse downloads" href="http://download.eclipse.org/eclipse/downloads/">eclipse project downloads</a>.</li>
<li>Find the Latest Release under Build Type in the Latest Downloads section and click the <a title="Eclipse 3.6 downloads" href="http://download.eclipse.org/eclipse/downloads/drops/R-3.6-201006080911/index.php">3.6 link</a> under Build Name.</li>
<li>Click <a title="Eclipse platform binary" href="http://download.eclipse.org/eclipse/downloads/drops/R-3.6-201006080911/index.php#PlatformRuntime">Platform Runtime Binary</a> in the left hand menu.</li>
<li>Choose for your OS by clicking one of the (http) links in the Download column; I chose <a href="http://download.eclipse.org/eclipse/downloads/drops/R-3.6-201006080911/download.php?dropFile=eclipse-platform-3.6-linux-gtk-x86_64.tar.gz">Linux (x86_64/GTK 2)</a>. Here&#8217;s the 32 bit version: <a href="http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops/R-3.6-201006080911/eclipse-platform-3.6-linux-gtk.tar.gz">Linux (x86/GTK 2)</a>.</li>
<li>You still need to pick a mirror! I use the <a href="http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops/R-3.6-201006080911/eclipse-platform-3.6-linux-gtk-x86_64.tar.gz&amp;url=http://ftp.osuosl.org/pub/eclipse/eclipse/downloads/drops/R-3.6-201006080911/eclipse-platform-3.6-linux-gtk-x86_64.tar.gz&amp;mirror_id=272">OSU Open Source Lab</a> link because it&#8217;s close to me and fast.</li>
<li>And finally, the download begins&#8230;</li>
</ul>
<p><strong>Install Eclipse</strong></p>
<p>Extract the downloaded package: <code>tar xvzf eclipse-platform-3.6-linux-gtk.tar.gz</code>. I rename the resulting eclipse directory to eclipse-3.6, move it to ~/.local,  and create a symlink in ~/.local/bin to the eclipse executable: <code>ln -s ~/.local/eclipse-3.6/eclipse ~/.local/bin/eclipse</code></p>
<p><strong>Configure Eclipse</strong></p>
<p>Edit ~/.local/eclipse-3.6/eclipse.ini. Find the line containing &#8220;-vmargs&#8221;. Add a new line directly below that: <code>-Djava.library.path=/usr/lib/jni</code>. Save and close. Fire up Eclipse.</p>
<p><strong>Install Aptana</strong></p>
<ul>
<li>Help &gt; Install New Software&#8230; &gt; Add
<ul>
<li>Eclipse update URL: <a href="http://update.aptana.com/install/studio">http://update.aptana.com/install/studio</a></li>
</ul>
</li>
<li>Click OK, click the Aptana Studio checkbox, click Next, click Finish, wait&#8230;, click Yes to restart Eclipse</li>
<li>When Eclipse restarts, a Customize Aptana Studio window should open automatically&#8230;</li>
</ul>
<p><strong>Install PyDev</strong></p>
<p>Eclipse update URL: <a href="http://pydev.org/updates">http://pydev.org/updates</a></p>
<p><strong>Install MercurialEclipse</strong></p>
<p>Eclipse update URL: <a href="http://cbes.javaforge.com/update">http://cbes.javaforge.com/update</a></p>
<p><strong>Install Subclipse</strong></p>
<p>Prerequisite: <code>sudo apt-get install libsvn-java</code></p>
<p>Eclipse update URL:  <a href="http://subclipse.tigris.org/update_1.6.x">http://subclipse.tigris.org/update_1.6.x</a> (select all required items under Subclipse checkbox)</p>
<p>After installation:</p>
<ul>
<li>Preferences &gt; General &gt; Editors &gt; Text Editors &gt; Quick Diff:</li>
<li>Check &#8216;Enable quick diff&#8217; and &#8216;Show differences in overview ruler&#8217;</li>
<li>Use this reference source: Pristine SVN Copy</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2009/06/29/eclipse-for-python-web-development-on-ubuntu/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Supervisor now supports Python 2.6</title>
		<link>http://wyattbaldwin.com/2009/05/26/supervisor-now-supports-python-26/</link>
		<comments>http://wyattbaldwin.com/2009/05/26/supervisor-now-supports-python-26/#comments</comments>
		<pubDate>Tue, 26 May 2009 18:26:24 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=317</guid>
		<description><![CDATA[I&#8217;ve been using Supervisor for a few months now to manage some app servers at work. Good stuff; solid. My only gripe with it was that it didn&#8217;t run properly under Python 2.6[1,2]. I had to install Python 2.5 just &#8230; <a href="http://wyattbaldwin.com/2009/05/26/supervisor-now-supports-python-26/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been using Supervisor for a few months now to manage some app servers at <a href="http://trimet.org/">work</a>. Good stuff; solid. My only gripe with it was that it didn&#8217;t run properly under Python 2.6[1,2]. I had to install Python 2.5 just to run Supervisor, which isn&#8217;t a super big deal but is kind of annoying. The latest release, 3.0a7, fixes this by including a &#8220;patched version of Medusa to allow Supervisor to run on Python 2.6.&#8221;</p>
<p>Note: I had to <code>`wget http://dist.supervisord.org/supervisor-3.0a7.tar.gz`</code> and easy_install that due to a network timeout[3]. I assume that&#8217;s because Supervisor is super popular and everyone&#8217;s upgrading.</p>
<p>[1] It did run under 2.6 but issued an error when starting up.<br />
[2] This was due to changes in the Python 2.6 stdlib, not a problem with Supervisor itself.<br />
[3] Suggestion: If possible, remove link from PyPI to http://supervisord.org/ so easy_install doesn&#8217;t get stuck there.</p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2009/05/26/supervisor-now-supports-python-26/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>oTidyBrowser is not defined</title>
		<link>http://wyattbaldwin.com/2008/12/02/otidybrowser-is-not-defined/</link>
		<comments>http://wyattbaldwin.com/2008/12/02/otidybrowser-is-not-defined/#comments</comments>
		<pubDate>Wed, 03 Dec 2008 00:13:17 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>
		<category><![CDATA[dev]]></category>
		<category><![CDATA[firebug]]></category>
		<category><![CDATA[firefox]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=255</guid>
		<description><![CDATA[If you&#8217;re tired of seeing this annoying error in Firebug, here&#8217;s the fix on Ubuntu (I stole this from here and condensed it to its Ubuntu specific essentials, though, of course, the procedure would be similar on other OSes): Locate &#8230; <a href="http://wyattbaldwin.com/2008/12/02/otidybrowser-is-not-defined/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re tired of seeing this annoying error in Firebug, here&#8217;s the fix on Ubuntu (I stole this from <a title="Long winded version of this fix" href="http://www.hackzilla.org/archives/2008/11/22/firefox-addon-html-validator/">here</a> and condensed it to its Ubuntu specific essentials, though, of course, the procedure would be similar on other OSes):</p>
<ul>
<li>Locate tidy.jar in your Firefox profile
<ul>
<li>Open $HOME/.mozilla in File Browser (starting at $HOME doesn&#8217;t work for some reason)</li>
<li>Click Search and type tidy.jar in the search bar</li>
</ul>
</li>
<li>Right click and <em>Open with &#8220;Archive Manager&#8221;</em></li>
<li>Go into content directory, right click tidyBrowser.js, and <em>Open With&#8230;</em> your favorite editor</li>
<li>Change line 220 from <code>if( oTidyBrowser.bTopLoadBusy==false )</code> to <code>if(oTidyBrowser &amp;&amp; oTidyBrowser.bTopLoadBusy==false )</code>
<ul>
<li>(Note: formatting left as I found it)</li>
</ul>
</li>
<li>Save and close tidyBrowser.js</li>
<li>Click Update in Archive Manager dialog that pops up after save</li>
<li>Restart Firefox</li>
<li>Rejoice at having removed one small annoyance from your life</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2008/12/02/otidybrowser-is-not-defined/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>&#8220;phrase from nearest book&#8221; meme</title>
		<link>http://wyattbaldwin.com/2008/11/12/phrase-from-nearest-book-meme/</link>
		<comments>http://wyattbaldwin.com/2008/11/12/phrase-from-nearest-book-meme/#comments</comments>
		<pubDate>Thu, 13 Nov 2008 01:53:19 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>
		<category><![CDATA[memes]]></category>
		<category><![CDATA[subversion]]></category>
		<category><![CDATA[svn]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=252</guid>
		<description><![CDATA[Via Grab the nearest book. Open it to page 56. Find the fifth sentence. Post the text of the sentence in your journal along with these instructions. Don’t dig for your favorite book, the cool book, or the intellectual one: &#8230; <a href="http://wyattbaldwin.com/2008/11/12/phrase-from-nearest-book-meme/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://agiletesting.blogspot.com/2008/11/phrase-from-nearest-book-meme.html">Via</a></p>
<ul>
<li>Grab the nearest book.</li>
<li>Open it to page 56.</li>
<li>Find the fifth sentence.</li>
<li>Post the text of the sentence in your journal along with these instructions.</li>
<li>Don’t dig for your favorite book, the cool book, or the intellectual one: pick the CLOSEST.</li>
</ul>
<p>Here&#8217;s mine, from <em>Pragmatic Version Control Using Subversion</em> 2nd Edition by Mike Mason:</p>
<blockquote><p>&#8220;After creating our sandbox repository, we used a <em>repository URL</em> to tell Subversion  what we wanted to check out.&#8221;</p></blockquote>
<p>Cool meme. Mine&#8217;s a little boring. Great book, though.</p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2008/11/12/phrase-from-nearest-book-meme/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Implementation of Dijkstra&#8217;s Single-Source Shortest-Paths in JavaScript</title>
		<link>http://wyattbaldwin.com/2008/08/19/implementation-of-dijkstras-single-source-shortest-paths-in-javascript/</link>
		<comments>http://wyattbaldwin.com/2008/08/19/implementation-of-dijkstras-single-source-shortest-paths-in-javascript/#comments</comments>
		<pubDate>Tue, 19 Aug 2008 23:52:03 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>
		<category><![CDATA[algorithms]]></category>
		<category><![CDATA[dijkstra]]></category>
		<category><![CDATA[geek-fun]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[oop]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=223</guid>
		<description><![CDATA[I&#8217;m working on a project where the client wants a cool sliding navigation effect. We&#8217;re implementing this with JavaScript/AJAX/DHTML. One of the constraints is that pages can only be reached via certain other pages. For example, if you&#8217;re on the &#8230; <a href="http://wyattbaldwin.com/2008/08/19/implementation-of-dijkstras-single-source-shortest-paths-in-javascript/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m working on a project where the client wants a cool sliding navigation effect. We&#8217;re implementing this with JavaScript/AJAX/DHTML.</p>
<p>One of the constraints is that pages can only be reached via certain other pages. For example, if you&#8217;re on the /portland/contact page and want to go to the /seattle/contact page, you&#8217;ll first slide up to /portland, then over to /seattle, then finally down to /seattle/contact.</p>
<p>After a while, it occurred to me that there were some similarities with another project I&#8217;ve been working on off and on for the last few years, byCycle.org, which is a bicycle trip planner ala Google Maps.</p>
<p>I had written a Python version of Dijkstra&#8217;s Single-Source Shortest-Paths (SSSP) for byCycle.org. That&#8217;s available on <a title="Dijkstar on PyPi" href="http://pypi.python.org/pypi/Dijkstar">PyPi as Dijkstar</a> (so named because it also <span style="text-decoration: line-through;">does</span> has the potential to do A*). I figured it wouldn&#8217;t be too hard to port the Python version to JavaScript, and it wasn&#8217;t.</p>
<p>There were a few snags, though. Most of it was just syntactic and semantic differences between the two languages. The biggest issue was that I use &#8220;heapq&#8220; in the Python version to maintain the costs to previously visited nodes in sorted order. JavaScript has no priority queue implementation that I could find, so I came up with a different solution that involves updating an Object (AKA &#8220;dict&#8220;) with costs to newly visited nodes and sorting the keys to pick the next node to visit. I&#8217;m assuming/hoping the underlying sort implementation is highly optimized.</p>
<p>Interestingly, I think I found at least one bug in the Python version, although I&#8217;ve been using that version for a couple years now with no known problems, so it must only be applicable in certain edge (no pun intended) cases (or maybe it&#8217;s due to some difference in the languages&#8211;need to take a closer look). I think the JS version came out cleaner, too.</p>
<p>If anyone&#8217;s interested, I&#8217;m releasing this under an MIT license. For now, you can <a title="Dijkstra in JavaScript" href="http://wyattbaldwin.com/code/dijkstra.js">get it from here</a>. Note that it depends on the util module that you can <a title="Namespaces and classes in JavaScript" href="http://wyattbaldwin.com/code/util.js">get from here</a>. The util module contains some other Python-inspired JavaScript, in particular a couple of functions for generating namespaces and classes. I might write another post about that at some point.</p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2008/08/19/implementation-of-dijkstras-single-source-shortest-paths-in-javascript/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>YUI TreeView with Ruby on Rails</title>
		<link>http://wyattbaldwin.com/2008/05/26/yui-treeview-with-ruby-on-rails/</link>
		<comments>http://wyattbaldwin.com/2008/05/26/yui-treeview-with-ruby-on-rails/#comments</comments>
		<pubDate>Tue, 27 May 2008 03:48:07 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[dev]]></category>
		<category><![CDATA[acts_as_tree]]></category>
		<category><![CDATA[recursion]]></category>
		<category><![CDATA[ruby]]></category>
		<category><![CDATA[ruby on rails]]></category>
		<category><![CDATA[yui]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=184</guid>
		<description><![CDATA[Here&#8217;s some code I&#8217;m using to generate a dynamic tree view using an acts_as_tree model with slug and title fields, the TreeView widget from YUI, and a Rails helper. I chopped out some of the code for clarity, so all &#8230; <a href="http://wyattbaldwin.com/2008/05/26/yui-treeview-with-ruby-on-rails/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s some code I&#8217;m using to generate a dynamic tree view using an acts_as_tree model with slug and title fields, the TreeView widget from YUI, and a Rails helper. I chopped out some of the code for clarity, so all this does is create a menu with the titles from the model, but the basic idea is there to expand on.</p>
<p><strong>Rails view/JavaScript</strong></p>
<pre>&lt;script type="text/javascript"&gt;
  var page_tree;
  page_tree_init = function () {
    page_tree = new YAHOO.widget.TreeView('page_tree');
    var root = page_tree.getRoot();
    &lt;% generate_page_nodes(@root) {} %&gt;
    page_tree.draw();
  };
  page_tree_init();
&lt;/script&gt;
</pre>
<p><strong>Ruby</strong></p>
<pre>def generate_page_nodes(node, &amp;block)
  parent = node.parent
  node_name = node.slug.gsub('-', '_')
  parent_node_name = parent.nil? ? 'root' : parent.slug.gsub('-', '_')
  js = &lt;&lt;-JS
    var #{node_name} = new YAHOO.widget.MenuNode('&lt;span class="node_title"&gt;#{node.title}&lt;/span&gt;',
                                                 #{parent_node_name});
  JS
  concat(js, block.binding)
  children = node.children
  children.each { |c| generate_page_nodes(c, &amp;block) } unless children.empty?
end
</pre>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2008/05/26/yui-treeview-with-ruby-on-rails/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Forest Park</title>
		<link>http://wyattbaldwin.com/2008/04/06/forest-park/</link>
		<comments>http://wyattbaldwin.com/2008/04/06/forest-park/#comments</comments>
		<pubDate>Mon, 07 Apr 2008 01:03:24 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[play]]></category>
		<category><![CDATA[forest park]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=135</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p><a href="http://wyattbaldwin.com/wp-content/uploads/2008/04/img_0485.jpg"><img class="alignnone size-medium wp-image-136" style="vertical-align: top;" title="Forest Park - standing on log" src="http://wyattbaldwin.com/wp-content/uploads/2008/04/img_0485-300x225.jpg" alt="" width="300" height="225" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2008/04/06/forest-park/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Decluttering the Desk</title>
		<link>http://wyattbaldwin.com/2008/04/05/decluttering-the-desk/</link>
		<comments>http://wyattbaldwin.com/2008/04/05/decluttering-the-desk/#comments</comments>
		<pubDate>Sat, 05 Apr 2008 10:57:40 +0000</pubDate>
		<dc:creator>Wyatt</dc:creator>
				<category><![CDATA[planet python]]></category>
		<category><![CDATA[work]]></category>
		<category><![CDATA[decluttering]]></category>
		<category><![CDATA[desk]]></category>
		<category><![CDATA[freelance]]></category>
		<category><![CDATA[productivity]]></category>
		<category><![CDATA[simplification]]></category>
		<category><![CDATA[working from home]]></category>
		<category><![CDATA[workstation]]></category>

		<guid isPermaLink="false">http://wyattbaldwin.com/?p=134</guid>
		<description><![CDATA[Today I read a post about decluttering your desk. Right now, I can&#8217;t find that post, but this page links to a bunch of similar and related articles. Those links are on the Zen Habits site, which I&#8217;ve started reading &#8230; <a href="http://wyattbaldwin.com/2008/04/05/decluttering-the-desk/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Today I read a post about decluttering your desk. Right now, I can&#8217;t find that post, but <a title="Decluttering links on Zen Habits" href="http://zenhabits.net/2007/10/ask-the-readers-best-tips-for-decluttering/">this page</a> links to a bunch of similar and related articles. Those links are on the <a title="Zen Habits" href="http://zenhabits.net/">Zen Habits</a> site, which I&#8217;ve started reading lately. Lots of interesting food for thought there.</p>
<p>So, I&#8217;m pretty tidy already, and my desk wasn&#8217;t that much of mess to begin with, but there were still quite a few unnecessary items accumulated there, like a printer I&#8217;m never going to use, a stapler I use maybe once a month, etc. I only spent about ten minutes decluttering, but the benefits were <em>huge</em>. So <strong><em>huge</em></strong> that I had to write it again in <a title="Ian Bicking: Reflection and Description Of Meaning" href="http://blog.ianbicking.org/2007/08/14/reflection-and-description-of-meaning/"><strong>bold<em> </em></strong>AND<em> italics</em></a>.</p>
<p>Along with office type stuff, I cleared off some knick knacks&#8211;little bits of art and what have you.</p>
<p>Did I mention the huge effect all this had? Wow. There&#8217;s a sense of openness and space. There&#8217;s more room to work and breathe. There&#8217;s also less distracting visual clutter.</p>
<p>This is only an anecdote, but I was more productive today than I&#8217;ve been in a while.</p>
<p>I recommend giving this a try. What do you really need on your desk and in your immediate working environment? What I&#8217;ve found, at least for myself, is that it&#8217;s actually not much. I&#8217;m guessing everyone&#8217;s got at least a couple items that can be tossed or sold or given away. Things that only get used once in a while can be put out of sight in an easy to reach place. Things that are visually interesting (photos, say) eventually become visually distracting, especially when there&#8217;s too much of it.</p>
<p>Of course, there&#8217;s no precise recipe, and everyone&#8217;s got their personal preferences. For me, just thinking about this, or anything, consciously is what&#8217;s important. The &#8220;right&#8221; changes naturally precipitate from awareness.</p>
]]></content:encoded>
			<wfw:commentRss>http://wyattbaldwin.com/2008/04/05/decluttering-the-desk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
