<?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>A Foolish Manifesto &#187; Uncategorized</title>
	<atom:link href="http://blog.afoolishmanifesto.com/archives/category/uncategorized/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.afoolishmanifesto.com</link>
	<description>fREWdiculous!</description>
	<lastBuildDate>Fri, 30 Jul 2010 02:57:07 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Announcing latest release of DBIx::Class::Helpers (2.004000)</title>
		<link>http://blog.afoolishmanifesto.com/archives/1404</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1404#comments</comments>
		<pubDate>Fri, 30 Jul 2010 02:57:07 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[dbix::class]]></category>
		<category><![CDATA[dbix::class::helpers]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1404</guid>
		<description><![CDATA[I am proud to announce a new release of DBIx::Class::Helpers. There are five major changes in this release. First off, the latest release adds DBIx::Class::Candy exports. So if you are using DBIx::Class::Candy to define a result, certain methods will be imported into your namespace. For example, DBIx::Class::Helper::Row::SubClass will export a subclass subroutine into your module. [...]]]></description>
			<content:encoded><![CDATA[<p>I am proud to announce a new release of <a href="http://search.cpan.org/perldoc?DBIx::Class::Helpers">DBIx::Class::Helpers</a>.  There are five major changes in this release.</p>
<p>First off, the latest release adds <a href="http://search.cpan.org/perldoc?DBIx::Class::Candy">DBIx::Class::Candy</a> exports.  So if you are using DBIx::Class::Candy to define a result, certain methods will be imported into your namespace.  For example, <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::Row::SubClass">DBIx::Class::Helper::Row::SubClass</a> will export a subclass subroutine into your module.  Not huge but nice nonetheless.</p>
<p>Next up, we have four shiny new components.  Two are ResultSet components and two are Result components.  One of the two ResultSet components was originally going to be in the core of <a href="http://search.cpan.org/perldoc?DBIx::Class">DBIx::Class</a>, but I decided to make a helper first to ensure that we iron out the details before we release it in core.  That component is <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::ResultSet::RemoveColumns">DBIx::Class::Helper::ResultSet::RemoveColumns</a>.  It does exactly what it sounds like.  With it you can do</p>
<div class="codecolorer-container perl vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="perl codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0000ff;">$resultset</span><span style="color: #339933;">-&gt;</span><span style="color: #006600;">search</span><span style="color: #009900;">&#40;</span><a href="http://perldoc.perl.org/functions/undef.html"><span style="color: #000066;">undef</span></a><span style="color: #339933;">,</span> <span style="color: #009900;">&#123;</span> <br />
&nbsp; &nbsp;remove_columns <span style="color: #339933;">=&gt;</span> <span style="color: #009900;">&#91;</span><span style="color: #ff0000;">'id'</span><span style="color: #009900;">&#93;</span> <br />
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span></div></td></tr></tbody></table></div>
<p>and the id column will no longer be selected in your ResultSet.  I am sure that it has some quirks, but I am not sure what they would be till people use this.  So have at it!</p>
<p>The next component, <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::ResultSet::AutoRemoveColumns">DBIx::Class::Helper::ResultSet::AutoRemoveColumns</a>, is based upon RemoveColumns.  Again, the name should make it clear what it does.  Currently it removes typically large columns by default, like text, blob, and the like.  See the docs for exactly what it removes.  (Note: later on I hope to add a component that adds lazy columns as detailed in <a href="http://blogs.perl.org/users/ovid/2010/07/lazy-database-columns-and-virtual-vertical-partitioning.html">ovid&#8217;s post here</a>.  Ovid if you are reading this I can&#8217;t comment on your blog.)</p>
<p>Next up is a fairly simple component, <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::Row::StorageValues">DBIx::Class::Helper::Row::StorageValues</a>.  It gives you access to the last known stored value of a column.  For example:</p>
<div class="codecolorer-container perl vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br /></div></td><td><div class="perl codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #b1b100;">my</span> <span style="color: #0000ff;">$foo</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">$resultset</span><span style="color: #339933;">-&gt;</span><span style="color: #006600;">search</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span> name <span style="color: #339933;">=&gt;</span> <span style="color: #ff0000;">'frew'</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><br />
&nbsp; &nbsp;<span style="color: #339933;">-&gt;</span><span style="color: #006600;">next</span><span style="color: #339933;">;</span><br />
<span style="color: #0000ff;">$foo</span><span style="color: #339933;">-&gt;</span><span style="color: #006600;">name</span><span style="color: #009900;">&#40;</span><span style="color: #ff0000;">'frioux'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;"># prints &quot;frew&quot;</span><br />
say <span style="color: #0000ff;">$foo</span><span style="color: #339933;">-&gt;</span><span style="color: #006600;">get_storage_value</span><span style="color: #009900;">&#40;</span><span style="color: #ff0000;">'name'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></div></td></tr></tbody></table></div>
<p>Building upon that we have my favorite new component:  <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::Row::OnColumnChange">DBIx::Class::Helper::Row::OnColumnChange</a>.  This module adds powerful hooks for calling methods when a column has been modified.  If you enable StorageValues for the column you hook into you get to look at the old value and the new value, which is pretty cool.  There are three hooks: <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::Row::OnColumnChange#before_column_change">before_column_change</a>, <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::Row::OnColumnChange#around_column_change">around_column_change</a>, and <a href="http://search.cpan.org/perldoc?DBIx::Class::Helper::Row::OnColumnChange#after_column_change">after_column_change</a>.  It automatically takes into account values changing because of accessors as well as by the arguments passed to update.  Also note that it allows you to tell it to wrap the call to update and the column change method in a transaction so that you can safely do things to other tables in the method.  Anyway, enough talk, here&#8217;s a small example:</p>
<div class="codecolorer-container perl vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br /></div></td><td><div class="perl codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">__PACKAGE__<span style="color: #339933;">-&gt;</span><span style="color: #006600;">add_column</span><span style="color: #009900;">&#40;</span>relationship_status <span style="color: #339933;">=&gt;</span> <span style="color: #009900;">&#123;</span><br />
&nbsp; &nbsp;data_type &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #339933;">=&gt;</span> <span style="color: #ff0000;">'varchar'</span><span style="color: #339933;">,</span><br />
&nbsp; &nbsp;<a href="http://perldoc.perl.org/functions/length.html"><span style="color: #000066;">length</span></a> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #339933;">=&gt;</span> <span style="color: #cc66cc;">30</span><span style="color: #339933;">,</span><br />
&nbsp; &nbsp;keep_storage_value &nbsp; &nbsp; &nbsp;<span style="color: #339933;">=&gt;</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">,</span><br />
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
__PACKAGE<span style="color: #339933;">-&gt;</span><span style="color: #006600;">before_column_change</span><span style="color: #009900;">&#40;</span>relationship_status <span style="color: #339933;">=&gt;</span> <span style="color: #009900;">&#123;</span><br />
&nbsp; &nbsp;method &nbsp; &nbsp;<span style="color: #339933;">=&gt;</span> <span style="color: #ff0000;">'happy_times'</span><span style="color: #339933;">,</span><br />
&nbsp; &nbsp;txn_wrap &nbsp;<span style="color: #339933;">=&gt;</span> <span style="color: #cc66cc;">1</span><span style="color: #339933;">,</span><br />
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #000000; font-weight: bold;">sub</span> happy_times <span style="color: #009900;">&#123;</span><br />
&nbsp; &nbsp;<span style="color: #b1b100;">my</span> <span style="color: #009900;">&#40;</span><span style="color: #0000ff;">$self</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">$old</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">$new</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">@_</span><span style="color: #339933;">;</span><br />
&nbsp; &nbsp;<span style="color: #0000ff;">$self</span><span style="color: #339933;">-&gt;</span><span style="color: #006600;">significant_other</span><span style="color: #339933;">-&gt;</span><span style="color: #006600;">update</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span> feelings <span style="color: #339933;">=&gt;</span> <span style="color: #ff0000;">'happy'</span> <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; <span style="color: #b1b100;">if</span> <span style="color: #0000ff;">$new</span> <span style="color: #b1b100;">eq</span> <span style="color: #ff0000;">'together'</span> <span style="color: #339933;">&amp;&amp;</span> <span style="color: #0000ff;">$old</span> <span style="color: #b1b100;">eq</span> <span style="color: #ff0000;">'apart'</span><br />
<span style="color: #009900;">&#125;</span></div></td></tr></tbody></table></div>
<p>So basically if relationship status changes from apart to togehter the significant other gets marked as happy, and all of this is done in a transaction, which is pretty awesome.</p>
<p>Anyway, hopefully this makes your job easier.  Have a good Friday!</p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1289" rel="bookmark" class="crp_title">New stuff in DBIx::Class::Helpers 2.00200</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1261" rel="bookmark" class="crp_title">Latest additions to DBIC::Helpers</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1234" rel="bookmark" class="crp_title">New stuff in DBIx::Class::Helpers</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1390" rel="bookmark" class="crp_title">Announcing DBIx::Class::Candy</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/274" rel="bookmark" class="crp_title">Paranoid Deletion in DBIx::Class</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1404/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>git-svn for the win</title>
		<link>http://blog.afoolishmanifesto.com/archives/1386</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1386#comments</comments>
		<pubDate>Tue, 27 Jul 2010 02:39:21 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[power tools]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1386</guid>
		<description><![CDATA[I have been using git more and more. I use it in all of my CPAN modules. I&#8217;m using git to the point where I expect everything else (that is, svn) to be just as powerful and fast. Unfortunately that just is not the case, and I&#8217;m still stuck with it for all but one [...]]]></description>
			<content:encoded><![CDATA[<p>I have been using git more and more.  I use it in all of my CPAN modules.  I&#8217;m using git to the point where I expect everything else (that is, svn) to be just as powerful and fast.  Unfortunately that just is not the case, and I&#8217;m still stuck with it for all but one project at work..  For example, the other day I wanted to find the last commit that my coworker made.  With git it would just be git log &#8211;author wes -1.  I couldn&#8217;t seem to figure out a way to do it with svn.  Maybe I&#8217;m just dumb?  Add on to that the fact that git log is mega fast but if you do svn log You Have Made a Mistake.  Also the colors!  Who doesn&#8217;t like the fact that git has colors out of the box?</p>
<p>To sum up the previous paragraph: <a href="http://www.kernel.org/pub/software/scm/git/docs/git-svn.html">I need to learn to use git-svn</a>.  Lets get started:</p>
<p>First off, you need to make a users file.  At my company that&#8217;s pretty easy since there are like, 12 people who have commit access to svn.  This is what it looks like:</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">david = David B. &lt;elduderino@hotmail.com&gt;<br />
fred = Fred K Beckhusin &lt;gnarlbot@hotmail.com&gt;<br />
frew = Arthur Axel &quot;fREW&quot; Schmidt &lt;frioux@gmail.com&gt;</div></td></tr></tbody></table></div>
<p>Put it in a file named &#8220;users&#8221; in the current directory.  All this does is substitute the svn names (on the left) for the git names (on the right.)  Next up, check out your repository:</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">git svn clone --stdlayout --authors-file=users svn://reposerver/foo/bar</div></td></tr></tbody></table></div>
<p>This assumes that /foo/bar has subdirs /trunk, /branches, and /tags.  If yours is different you&#8217;ll want to do something like the following:</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">git svn clone --trunk='/Developer' --tags='/Releases' --authors-file=users svn://reposerver/foo/bar</div></td></tr></tbody></table></div>
<p>Of course you might need to do some tweaking there.</p>
<p>Now, we have three other svn:externals repositories in our repo.  This is the most ghetto part of all of this, and it&#8217;s probably just because I haven&#8217;t done the appropriate research.  Again, if you know better, just tell me.  (Normally with git you&#8217;d do this with a submodule, but we aren&#8217;t going to do that because we want to directly check the &#8220;submodule&#8221; out from svn so we can commit back easily. If you don&#8217;t know what a submodule is, ignore this <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  )</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">git svn clone --stdlayout --authors-file=users svn://reposerver/svnexternal1 $to_name</div></td></tr></tbody></table></div>
<p>This will check out the svnexternal1 repo to a folder called $to_name.  If you need to check it out to a separate subdir either cd into that dir or change $to_name.</p>
<p>You don&#8217;t want to check that into svn because your coworkers already have an svn:externals for that.  Normally this would be done with .gitignore, but we won&#8217;t use that because your coworkers don&#8217;t want a .gitignore file in their repository.  Instead you&#8217;ll use .git/info/exclude, which is the same thing but not inside of the repo.  Just put $to_name on a single line in that file and it won&#8217;t show up in your available changes when you need to commit.</p>
<p>Speaking of commiting, how do you commit?  Normally your workflow should be the way it is with git.  You commit often and when you are ready for a feature to go to the team you push it out.  I usually rebase and clean up commits before I push, but that&#8217;s up to you.  The main difference is that you don&#8217;t do git push &#8230;  Instead you&#8217;ll do</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">git svn rebase &amp;&amp; git svn dcommit</div></td></tr></tbody></table></div>
<p>git svn rebase actually checks out the new changes from svn and puts them in your repository before the changes you&#8217;ve already committed.  If there are conflicts you&#8217;ll have to deal with those of course, but otherwise it will just pull in the changes and then use dcommit to submit new changes. You should not have any uncheckedin changes when you do this (it will complain if you do) because dcommit actually does a different kind of rebase after checking in changes.  It changes your commits to include the svn id so that the git commits match up with the svn commits.</p>
<p>In general that&#8217;s all there is to it.  At some point I&#8217;d like to do a post about how I use git rebase fairly often in my workflow, but this I think is a lot more important.  Oh and <a href="http://mislav.uniqpath.com/2010/07/git-tips/">here</a> are some cool new git features I learned today.  Enjoy <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1318" rel="bookmark" class="crp_title">commands!</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1349" rel="bookmark" class="crp_title">DBIx::Class has migrated to git!</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/267" rel="bookmark" class="crp_title">Rakudo Autobuilder</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1344" rel="bookmark" class="crp_title">Syncing with Multiple Git Repos</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1255" rel="bookmark" class="crp_title">Getting portable</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1386/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>New stuff in Devel::Dwarn</title>
		<link>http://blog.afoolishmanifesto.com/archives/1396</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1396#comments</comments>
		<pubDate>Fri, 23 Jul 2010 04:04:37 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1396</guid>
		<description><![CDATA[Yesterday I released a new (major version of) Devel::Dwarn, or what is technically Data::Dumper::Concise. But those in the know call it Devel::Dwarn. If you did not already know, Devel::Dwarn is sugar + good defaults for Data::Dumper. Check it out. Drool. Use it. Anyway, I figured the new changes were worth mention on the internet, so [...]]]></description>
			<content:encoded><![CDATA[<p>Yesterday I released a new (major version of) <a href="http://search.cpan.org/perldoc?Devel::Dwarn">Devel::Dwarn</a>, or what is technically Data::Dumper::Concise.  But those in the know call it Devel::Dwarn.</p>
<p>If you did not already know, Devel::Dwarn is sugar + good defaults for Data::Dumper.  Check it out.  Drool.  Use it.</p>
<p>Anyway, I figured the new changes were worth mention on the internet, so here goes:</p>
<p>First off, Dwarn now pays attention to list context, so in list context it uses the original behavior, but in scalar context it does what DwarnS does.  One of my coworkers got bit by the Dwarn vs DwarnS distinction so much that he only uses DwarnS now.  Hopefully this will remedy that issue.</p>
<p>Next up is that Dumper (and also Dwarn because it uses Dumper) no longer returns an object when passed zero arguments.  If you used that I&#8217;m sorry; but it just bit most of us when we tried Dwarn(@foo) and @foo was an empty list.  Sorry, it&#8217;s gone!</p>
<p>Last, is the brand new DwarnN.  DwarnN is a neat debugging tool which will label your output by the variables passed in.  So if you do DwarnN $foo it will print &#8216;$foo => &#8216; . Dumper($foo).  Not world changing, but still very helpful!</p>
<p>Hopefully this will ease your job that much more!</p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1300" rel="bookmark" class="crp_title">Announcing Log::Contextual</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1072" rel="bookmark" class="crp_title">Perl 6 in Perl 5 FOR THE WIN</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/633" rel="bookmark" class="crp_title">Future Perl</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1207" rel="bookmark" class="crp_title">JAP(5|6)H</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/868" rel="bookmark" class="crp_title">Finding the Optimum Meeting Location</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1396/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Announcing DBIx::Class::Candy</title>
		<link>http://blog.afoolishmanifesto.com/archives/1390</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1390#comments</comments>
		<pubDate>Wed, 21 Jul 2010 05:17:28 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[dbix::class]]></category>
		<category><![CDATA[DBIx::Class::Candy]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1390</guid>
		<description><![CDATA[Over a year ago I read this blog post. To be honest at the time I thought it was mostly silly and I still feel that way. The things that are important to me in an ORM are capabilities, not subjective prettiness of code. But, I also get tired of typing repetitive things, especially __PACKAGE__->. [...]]]></description>
			<content:encoded><![CDATA[<p>Over a year ago I read <a href="http://www.dmclaughlin.com/2009/04/19/ugly-perl-a-lesson-in-the-importance-of-api-design/">this blog post</a>.  To be honest at the time I thought it was mostly silly and I still feel that way.  The things that are important to me in an ORM are capabilities, not subjective prettiness of code.  But, I also get tired of typing repetitive things, <strong>especially</strong> __PACKAGE__->.  That&#8217;s just too many shift keys!  So after working on a few different modules and accruing various bits of knowledge here and there I learned what I needed to to create a sugar layer for <a href="http://search.cpan.org/perldoc?DBIx::Class">DBIx::Class</a> that doesn&#8217;t throw the baby out with the bath-water.</p>
<hr />
<p>I am proud to announce the initial, development version of <a href="http://search.cpan.org/perldoc?DBIx::Class::Candy">DBIx::Class::Candy</a>, which should be coming to a CPAN mirror near you very soon.  If you just can&#8217;t wait, use <a href="http://search.cpan.org/perldoc?App::CPAN::Fresh">cpanf</a> to get it <strong>right now</strong>.  The basic gist of it is that you can use:</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&nbsp;package MyApp::Schema::Result::Artist;<br />
<br />
&nbsp;use DBIx::Class::Candy;<br />
<br />
&nbsp;table 'artists';<br />
<br />
&nbsp;column id =&gt; {<br />
&nbsp; &nbsp;data_type =&gt; 'int',<br />
&nbsp; &nbsp;is_auto_increment =&gt; 1,<br />
&nbsp;};<br />
<br />
&nbsp;column name =&gt; {<br />
&nbsp; &nbsp;data_type =&gt; 'varchar',<br />
&nbsp; &nbsp;size =&gt; 25,<br />
&nbsp; &nbsp;is_nullable =&gt; 1,<br />
&nbsp;};<br />
<br />
&nbsp;primary_key 'id';<br />
<br />
&nbsp;has_many albums =&gt; 'A::Schema::Result::Album', 'artist_id';<br />
<br />
&nbsp;1;</div></td></tr></tbody></table></div>
<p>instead of</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&nbsp;package MyApp::Schema::Result::Artist;<br />
<br />
&nbsp;use strict;<br />
&nbsp;use warnings;<br />
&nbsp;use base 'DBIx::Class::Core';<br />
<br />
&nbsp;__PACKAGE__-&gt;table('artists');<br />
<br />
&nbsp;__PACKAGE__-&gt;add_columns(<br />
&nbsp; &nbsp;id =&gt; {<br />
&nbsp; &nbsp; &nbsp;data_type =&gt; 'int',<br />
&nbsp; &nbsp; &nbsp;is_auto_increment =&gt; 1,<br />
&nbsp; &nbsp;},<br />
&nbsp; &nbsp;name =&gt; {<br />
&nbsp; &nbsp; &nbsp;data_type =&gt; 'varchar',<br />
&nbsp; &nbsp; &nbsp;size =&gt; 25,<br />
&nbsp; &nbsp; &nbsp;is_nullable =&gt; 1,<br />
&nbsp; &nbsp;}<br />
&nbsp;);<br />
<br />
&nbsp;__PACKAGE__-&gt;set_primary_key('id');<br />
<br />
&nbsp;__PACKAGE__-&gt;has_many( albums =&gt; 'A::Schema::Result::Album', 'artist_id' );<br />
<br />
&nbsp;1;</div></td></tr></tbody></table></div>
<p>There are a few other features, like having it turn on 5.10 or 5.12 features, use a non standard base, and more.  <a href="http://search.cpan.org/perldoc?DBIx::Class::Candy"><strong>Check it out now!</strong></a></p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1404" rel="bookmark" class="crp_title">Announcing latest release of DBIx::Class::Helpers (2.004000)</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1286" rel="bookmark" class="crp_title">Do Passwords Right</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/913" rel="bookmark" class="crp_title">OpenID with Catalyst and more</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/274" rel="bookmark" class="crp_title">Paranoid Deletion in DBIx::Class</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1289" rel="bookmark" class="crp_title">New stuff in DBIx::Class::Helpers 2.00200</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1390/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Being a Speaker at YAPC 2010</title>
		<link>http://blog.afoolishmanifesto.com/archives/1365</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1365#comments</comments>
		<pubDate>Sat, 26 Jun 2010 17:15:41 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[dbix::class]]></category>
		<category><![CDATA[dbix::class::deploymenthandler]]></category>
		<category><![CDATA[DBIx::Exceptions]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[YAPC]]></category>
		<category><![CDATA[yapc2010]]></category>
		<category><![CDATA[YAPC::NA]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1365</guid>
		<description><![CDATA[This year Rob Kinyon and mst convinced me to do some speaking at YAPC. I ended up doing three forty minute talks. The DBIx::Class one was certainly the easiest, but also the one I was least invested in. I didn&#8217;t write DBIx::Class and it&#8217;s a big enough project that the slides nearly wrote themselves. I [...]]]></description>
			<content:encoded><![CDATA[<p>This year Rob Kinyon and mst convinced me to do some speaking at YAPC.  I ended up doing three forty minute talks.  The <a href="http://afoolishmanifesto.com/dbic-intro/slideshow.html">DBIx::Class</a> one was certainly the easiest, but also the one I was least invested in.  I didn&#8217;t write DBIx::Class and it&#8217;s a big enough project that the slides nearly wrote themselves.  </p>
<p>I also did a talk on <a href="http://afoolishmanifesto.com/dbicdh-intro/slideshow.html">DBIx::Class::DeploymentHandler</a>.  I am a little frustrated with how this talk went down.  I am confident that DBICDH is an excellent piece of software that can do some really cool things and I kinda botched the end of the talk (very abrupt.)  I wouldn&#8217;t call the talk a failure; it had a great turnout and at the very least I got to discuss features with jnapiorkowski, which was fun.</p>
<p>My third talk was about <a href="http://afoolishmanifesto.com/dbie-intro/slideshow.html">DBIx::Exceptions</a>.  It was hard for a couple reasons; first off DBIE isn&#8217;t actually done yet.  That certainly is not conducive to talking about something.  Second, what it ultimately does really isn&#8217;t that complicated.  The module is almost entirely a function of doing some research.  So while I think that the subject is good and interesting, I don&#8217;t think it warrants a whole 40 minute talk.  I actually had a long discussion with Rob about exceptions in general and he strongly supported the point of view that exceptions in any language are fundamentally flawed.  I&#8217;ll turn that into a blog post at some point.</p>
<p>I finished all three of the talks in less than forty minutes; I think that was a combination of me talking too fast (DBIC + DBICDH) and not actually having enough content (DBIE.)  I would have done better were I less nervous, which should be less and less of a problem as a I practice technical speaking more.  I actually did a lot of presentations in college and rarely had these issues, but in college I almost never spoke about software I wrote and my talks were usually from 10 to 20 minutes long.  Another thing that I feel is important is that I need to try to add humor to my talks.  The talks that are the most engaging are also the ones that are entertaining.  I&#8217;m not sure I how I could work in jokes etc, but I need to try to do that next time.</p>
<p>In other news, I&#8217;m pretty worn out in general from YAPC.  I just need a break.  So while I will do bug fixes and whatnot for my existing modules, and I still hope to release DBIx::Exceptions very soon, I&#8217;m going to try to chill out for about a month before taking on any of the other large ideas I have in mind for the future.  Or at least I won&#8217;t start them on purpose <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1358" rel="bookmark" class="crp_title">YAPC Talks I Think Are Worth Note</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1352" rel="bookmark" class="crp_title">Announcing DBIx::Class::DeploymentHandler</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/844" rel="bookmark" class="crp_title">YAPC::NA &#8211; Day -1: Moose</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/527" rel="bookmark" class="crp_title">Ext Conference Day 2</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/899" rel="bookmark" class="crp_title">Model Based Security</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1365/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>YAPC Talks I Think Are Worth Note</title>
		<link>http://blog.afoolishmanifesto.com/archives/1358</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1358#comments</comments>
		<pubDate>Wed, 23 Jun 2010 17:47:56 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[YAPC]]></category>
		<category><![CDATA[YAPC::NA]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1358</guid>
		<description><![CDATA[So I just got back from my second YAPC. Again I had to leave early, but not as early as last time, so that&#8217;s good. Instead of summarizing every single talk I went to, I&#8217;d like to highlight some of my (most and least) favorites. Day 1 Not Quite Perl (NQP) A lightweight Perl 6 [...]]]></description>
			<content:encoded><![CDATA[<p>So I just got back from my second YAPC.  <strong>Again</strong> I had to leave early, but not as early as last time, so that&#8217;s good.  Instead of summarizing every single talk I went to, I&#8217;d like to highlight some of my (most and least) favorites.</p>
<h1>Day 1</h1>
<h2><a href="http://pmichaud.com/2010/pres/yapcna-nqp/slides/start.html">Not Quite Perl (NQP) A lightweight Perl 6</a></h2>
<p>I can&#8217;t help but follow this since I see Patrick fairly regularly in our Dallas.p6m meetings; which is really half Perl 5 and half Perl 6.  NQP is an amazing bootstrapping language for Perl 6 that is actually already self-hosting (written in itself!!!) and can do a lot of neat things.  And of course Patrick is an excellent and humble speaker, which always helps.</p>
<p>Take a look at the slides (linked to above, page up and page down for next and prev slides) for more information.</p>
<p>For a language as minimal as they could get away with it&#8217;s extremely pretty.  Note: For all the talks mentioned here, slides != talk.</p>
<h2><a href="http://www.slideshare.net/miyagawa/plack-at-yapcna-2010">Plack &#8211; Perl web framework &#038; server superglue</a></h2>
<p>Plack is very cool tech, even though Perl is late to the concepts it brings us.  The cool thing about the talk was that it starts off really slow and then ramps up to some really amazing middleware that just blows my mind.  Miyagawa was an excellent speaker and had lots of fun little jokes in his talks too.</p>
<h2>Fey and Fey::ORM</h2>
<p>I was told to go to this talk by ribasushi with the sole idea of stealing ideas for DBIx::Class.  I was generally unimpressed with the ORM part, but Fey is far better than SQL::Abstract it seems like.  Rolsky is very adamant about having no magic in his core, which is fine, but it typically means baseline code will be ugly.  It&#8217;s certainly a trade off.  He has a really cool autojoin feature, which I envy but also know that ribasushi already wants to implement that to an extent.  Our $rs->as_query is cool, but he has something like that for EVERYTHING, which yields some interesting results.  Of course this is due to his thoughts that pretty stuff belongs in a sugar layer.  He has much more powerful relationships, which I envy for now but I also know that we have a branch in progress to give us arbitrarily complex (???) relationships.  It seems like he has a global schema, which is too bad, but that&#8217;s just how things work sometimes.  He wants to keep per db stuff out of the core, which I can certainly see being a good thing, but I also think it&#8217;s good that we try to keep all of our per db code up to snuff, so theres a tradeoff there.</p>
<p>Overall I thought rolsky was very honest about the fact that Fey (and Fey::ORM) is about doing things differently due to taste and that&#8217;s completely fine.  I <strong>definitely</strong> envy his SQL generation code, but I&#8217;d rather SQLA2.</p>
<h2><a href="http://yapc2010.com/yn2010/talk/2551">Lightning Talks 1</a></h2>
<h3><a href="http://yapc2010.com/yn2010/talk/2924">A/B testing with Perl‎</a></h3>
<p>Look around at some docs on AB testing.  The stuff they did with this was amazing.  Forget hallway testing.  This is where it&#8217;s at for usability.</p>
<h3><a href="http://yapc2010.com/yn2010/talk/2864">perlopquick &#8211; a quick reference for Perl 5 operators‎</a></h3>
<p>Ever want to look up how //= works?  Not easy.  Check out perlopquick.  Awesome stuff for the future of core docs.</p>
<h1>Day 2</h1>
<h2>Perl for CS Grad Students</h2>
<p>For this talk I have to give a little bit of background.  This year it was attempted to film every single one of the talks unless the speaker explicitly said not to.  Cameras et al were paid for by the conference&#8217;s budget.  Of course, cameras are not all you need.  You also need someone to run the cameras.  It turns out that <strong>ONE MAN</strong> (his name is Krishna) did <strong>ALL</strong> of that for all <strong>five</strong> tracks.  Of course the videos won&#8217;t be perfect, but if this becomes a trend it would be a great thing for all of perl.</p>
<p>The speaker of this talk, like probably 33% of all the speakers in general, had technical difficulties getting his mac to work exactly how how wanted with the projector.  He (reasonably) got frustrated at this and the wasted time it caused.  What bothers me is that krishna was setting up the camera (and mic) as he did in every room every morning and walt said, &#8220;Why are you even here?&#8221; to krishna, presumably thinking that he was staff of the college (which is of course a great reason to treat a person poorly) and continued to lash out complaining about his technical difficulties.  I guess to put a positive spin on this I got to know krishna better for it and I think we all owe him a beer or curry or whatever for all of his hard work (and apparently taking abuse) for doing WAY too much A/V for one person.</p>
<p>The talk was ok.</p>
<h2>Iron Mad: The Iron Man Forfeit Talk‎</h2>
<p>This was mst&#8217;s Iron Man forfeit talk.  Watch the video, it&#8217;s hilarious.  I&#8217;m not sure much more can be said <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<h2>perl5i: Perl 5 Improved‎</h2>
<p>I heard about perl5i last year and I thought it was neat.  Now I think it&#8217;s excellent enough that I might use it in code at work.  One thing I think is very good about it is the fact that you <strong>must</strong> use a version number when using the module, because it is expressly backwards <strong>in</strong>compatible.  Take a look at the module.  Very fun.</p>
<h2><a href="http://yapc2010.com/yn2010/talk/2552">Lightning Talks 2</a></h2>
<h3><a href="http://yapc2010.com/yn2010/talk/2935">Reframing the Death of Perl‎</a></h3>
<p>This basically looked at the psychological term called &#8220;framing.&#8221;  The gist of the talk: when you say &#8220;Perl is not dead&#8221; people see &#8220;perl is dead.&#8221;  So instead you have to completely reframe and say &#8220;Perl is alive&#8221; etc.  We ended up all yelling perl is alive and scaring prospective students that were visiting Ohio State.  Awesome.</p>
<h3><a href="http://yapc2010.com/yn2010/talk/2705">Musical Intervals and Chords</a></h3>
<p>This was a talk by ology about (duh) music.  Very cool stuff.  I wish I could have talked with him more than I did for the few minutes that I did, and especially I wish I had discussed the music stuff with him.   Unfortunately he ran out of time in his talk, but what he did say was getting very cool <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<h3><a href="http://yapc2010.com/yn2010/talk/2693">How I mastered English with Perl</a></h3>
<p>This was a hilarious talk by a man who moved to the US from Japan and learned some english with perl.  It focused on Lingua::EN::Inflect, using CPAN as a dictionary, and adorable daughters.</p>
<h2>Auction</h2>
<p>Not really a talk per se, but still a fun time.  Apparently the auction usually takes hours, but this only took 1.5 hours, so not really that bad, and still a lot of fun.  I got some O&#8217;Reilly coasters (beer mats for you brits) and wes got the new Effective Perl book + autographs.  Very cool.</p>
<h1>Day 3</h1>
<h2><a href="http://yapc2010.com/yn2010/talk/2642">Path::Dispatcher</a></h2>
<p>This talk was interesting in structure.  It started off fairly slowly but got super cool as it built on itself.  It made me want to start writing CLI apps.  The fact that it yields such a nice API makes it hard for me to justify why I like the way that catalyst does it&#8217;s dispatching (all spread out) but I do think that different ways of doing things are valid.  I would love to write some kind of text adventure game with this.  Maybe I&#8217;ll use it to create a Perl tutorial game?</p>
<h2><a href="http://www.pmichaud.com/2010/pres/yapcna-perl6/slides/start.html">Cool Perl 6 you can do today</a></h2>
<p>Again, this was Patrick.  This talk makes me want to start writing my one off scripts in Perl 6.  Unfortunately some of my more interesting &#8220;one off scripts&#8221; involve creating a DBIC schema and shoving data into an sqlite database so that I can get a feel for my data.  Either way, check out the slides, very cool stuff.  Also note: I downloaded and installed rakudo in the talk and actually played with it.  It&#8217;s been a while since I&#8217;ve done that and I assure you it&#8217;s only gotten easier.</p>
<p>All in all it was a great conference.  I liked it better than last year despite the stress of three (supposed to be) forty minute talks.  I&#8217;ll discuss that in my next post <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1365" rel="bookmark" class="crp_title">Being a Speaker at YAPC 2010</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/844" rel="bookmark" class="crp_title">YAPC::NA &#8211; Day -1: Moose</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/847" rel="bookmark" class="crp_title">YAPC Day 1</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/543" rel="bookmark" class="crp_title">Ext Day 3</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/809" rel="bookmark" class="crp_title">Dallas.p6m: June</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1358/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Announcing DBIx::Class::DeploymentHandler</title>
		<link>http://blog.afoolishmanifesto.com/archives/1352</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1352#comments</comments>
		<pubDate>Fri, 11 Jun 2010 03:33:54 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[DBIC]]></category>
		<category><![CDATA[dbicdh]]></category>
		<category><![CDATA[dbix::class]]></category>
		<category><![CDATA[dbix::class::deploymenthandler]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1352</guid>
		<description><![CDATA[Do you remember when you first realized that you were not the only person with a perspective in the world? I do. I was 5ish and I remember looking into the car to the left of me and seeing another person looking at me from their respective car. I remember thinking, &#8220;This is not what [...]]]></description>
			<content:encoded><![CDATA[<p>Do you remember when you first realized that you were not the only person with a perspective in the world?  I do.  I was 5ish and I remember looking into the car to the left of me and seeing another person looking at me from their respective car.  I remember thinking, &#8220;This is not what it is like from their point of view.&#8221;  I distinctly remember reevaluating things all day that day.  I am sure that I was still just as selfish and childish as I was before that moment, but it certainly changed my point of view.</p>
<hr />
I am proud to announce, after three months of work, that <a href="http://search.cpan.org/perldoc?DBIx::Class::DeploymentHandler">DBIx::Class::DeploymentHandler</a> is at a point where I&#8217;d call it stable and usable.  DBICDH is a much more flexible replacement for DBIx::Class::Schema::Versioned.  <a href="http://desert-island.me.uk/~castaway/blog/index.html">Castaway</a> did a great job with making Schema::Versioned, and without it there is no way I would have gotten started on DBICDH, but it is my sincere hope that this will be the recommended tool instead of Schema::Versioned from now on.  <a href="http://www.linkedin.com/in/robkinyon">Rob Kinyon</a> and <a href="http://www.shadowcat.co.uk/blog/matt-s-trout/">mst</a> had significant influence on the overall API and design, so it is at least influenced by Very Smart people.  ribasushi helped a <strong>lot</strong> later on by pointing out poorly named methods and directories as well as helping me use <a href="http://search.cpan.org/perldoc?SQL::Translator">SQL::Translator</a> correctly since he knows all of its weaknesses and strengths. </p>
<p>Major features this has over DBIx::Class::Schema::Versioned:</p>
<ul>
<li>Multiple files for migrations</li>
<li>Perl files in migrations</li>
<li>Shared Perl/SQL for different databases</li>
<li>Downgrades</li>
<li>Not to mention extreme customizability</li>
</ul>
<p>So try it out today!  I am looking forward to getting bug reports soon <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Oh also, if it does not quite do what you want&#8230;</p>
<p><strong>PATCHES WELCOME</strong>! <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':-D' class='wp-smiley' /> </p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1390" rel="bookmark" class="crp_title">Announcing DBIx::Class::Candy</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1344" rel="bookmark" class="crp_title">Syncing with Multiple Git Repos</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1365" rel="bookmark" class="crp_title">Being a Speaker at YAPC 2010</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1207" rel="bookmark" class="crp_title">JAP(5|6)H</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1031" rel="bookmark" class="crp_title">Why should I use an ORM?</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1352/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>DBIx::Class has migrated to git!</title>
		<link>http://blog.afoolishmanifesto.com/archives/1349</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1349#comments</comments>
		<pubDate>Fri, 04 Jun 2010 00:10:12 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[dbix::class]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1349</guid>
		<description><![CDATA[Woohoo! git! I am so happy to announce that DBIx::Class has migrated to git! If people latch on well, this should benefit is in a number of ways. The first thing is that most people should appreciate is the ability to check in to source control without needing to commit to the remote repository. Not [...]]]></description>
			<content:encoded><![CDATA[<h1>Woohoo!  git!</h1>
<p>I am so happy to announce that <a href="http://search.cpan.org/perldoc?DBIx::Class">DBIx::Class</a> has migrated to git!  </p>
<p>If people latch on well, this should benefit is in a number of ways.  The first thing is that most people should appreciate is the ability to check in to source control without needing to commit to the remote repository.  Not only does this make things way faster, it also means that you can work sanely offline.  A lot of people did this before with SVK, but SVK is slow and a hassle (I think) to install and setup.</p>
<p>Another thing that this should help is our history.  I don&#8217;t mean to point out a specific person, I did this all the time with svn (it&#8217;s just the nature of the beast,) but <a href="http://dev.catalystframework.org/svnweb/bast/log/DBIx-Class/0.08/branches/extended_rels">take a look</a> at some of these commit messages.  The SVK merge messages are pretty obnoxious, but that&#8217;s not what I&#8217;m referring to.  The ones that bother me are the: &#8220;Oops,&#8221; &#8220;Typo,&#8221; &#8220;Thinko,&#8221; etc.  With git those can be cleanly squashed into another commit.  In fact, I would recommend cleaning up your history before you push every time.  This is how I do that:</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">git rebase --root --onto master --interactive</div></td></tr></tbody></table></div>
<p>That will rebase your current branch (all of it) onto master, and give you an editor that will let you fix commit messages, merge commits, and more.  If people do not do this I fully intend to do it myself before I merge a branch in, if I do.  And that brings me to the next point which we shall discuss.</p>
<h1>Workflow</h1>
<p>We toyed with the idea of setting up git such that everyone would just use github or gitorious or whatever and ribasushi and I would be in charge of merging remote branches into the DBIC master, but mst veto&#8217;d the idea in favor of a more communal approach.  Basically the workflow we will use looks like the following:</p>
<ol>
<li>Get a commitbit (liberal policy)</li>
<li>Clone the repo (dbsrgits@git.shadowcat.co.uk:DBIx-Class.git)</li>
<li>Make a topic branch based on what you are doing, do work on it, whatever</li>
<li>Push branch to repo</li>
<li>Ask a fellow DBIC&#8217;er to review the branch, that includes me, ribasushi, Caelum, and really anyone else with a commitbit</li>
<li>If the reviewer thinks everything is sane, <strong>the reviewer</strong> will merge the branch in; to be a bit more clear, you should not merge your own branch into master, that is the reviewer&#8217;s job</li>
<li>Delete your branch locally and remotely after everything is merged in, and work on other stuff!</li>
</ol>
<p>A note about merges, don&#8217;t merge master into your branch.  It makes for yucky history.  Instead, rebase your branch onto master.  Currently the thought is that <strong>anything</strong> except for master can be rebased.  Of course if you and another dev are working in the branch you might want to keep that to a minimum, but at the very least you should be rebasing to squash silly commits before you push, and then when you do the final merge into master you should rebase first, so that history remains sane.  Of course, the best time to rebase to fix silly history is before you push, and the best time to rebase to make it so that you are fastforwarding master is right before the final merge, so try to only do that then.</p>
<p>At some point I plan on writing a DBIx::Class::Manual::Contributing in the spirit of <a href="http://search.cpan.org/perldoc?Moose::Manual::Contributing">Moose::Manual::Contributing</a>, but ours will be significantly more lax.  In the meantime, just swing by #dbix-class, get your commitbit, and help out!</p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1386" rel="bookmark" class="crp_title">git-svn for the win</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1344" rel="bookmark" class="crp_title">Syncing with Multiple Git Repos</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1255" rel="bookmark" class="crp_title">Getting portable</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/267" rel="bookmark" class="crp_title">Rakudo Autobuilder</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/428" rel="bookmark" class="crp_title">Git Workflow for Rakudo</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1349/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Syncing with Multiple Git Repos</title>
		<link>http://blog.afoolishmanifesto.com/archives/1344</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1344#comments</comments>
		<pubDate>Sun, 23 May 2010 06:55:36 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[community]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[github]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1344</guid>
		<description><![CDATA[This is almost entirely so that I remember how to do this. A big thanks for arcanez for showing me this in the first place. The Problem In the Perl community, numerous important git repositories are hosted at shadowcat, but of course if you went to that url you would not be able to see [...]]]></description>
			<content:encoded><![CDATA[<p>This is almost entirely so that I remember how to do this.  A big thanks for <a href="http://warpedreality.org/">arcanez</a> for showing me this in the first place.</p>
<h1>The Problem</h1>
<p>In the Perl community, <a href="http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo/Class-C3.git">numerous</a> <a href="http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo/Class-MOP.git">important</a> <a href="http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit/Devel-Declare.git">git</a> <a href="http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit/local-lib.git">repositories</a> are hosted at <a href="http://git.shadowcat.co.uk/gitweb/gitweb.cgi">shadowcat</a>, but of course if you went to that url you would not be able to see all the work that I have spent on each of those projects.  I like the fact that github has a nice concise view of my work.</p>
<h1>The Solution</h1>
<p>The following is an example of a section from my .git/config in my DBIx-Class-DeploymentHandler:</p>
<div class="codecolorer-container text vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">[remote &quot;all&quot;]<br />
&nbsp; &nbsp;url = dbsrgits@git.shadowcat.co.uk:DBIx-Class-DeploymentHandler.git<br />
&nbsp; &nbsp;url = git@github.com:frioux/DBIx-Class-DeploymentHandler.git<br />
[remote &quot;origin&quot;]<br />
&nbsp; &nbsp;fetch = +refs/heads/*:refs/remotes/origin/*<br />
&nbsp; &nbsp;url = dbsrgits@git.shadowcat.co.uk:DBIx-Class-DeploymentHandler.git<br />
[remote &quot;github&quot;]<br />
&nbsp; &nbsp;fetch = +refs/heads/*:refs/remotes/github/*<br />
&nbsp; &nbsp;url = git@github.com:frioux/DBIx-Class-DeploymentHandler.git</div></td></tr></tbody></table></div>
<p>This lets you push to origin, github, or all.  I tend to only pull from origin and push to all.  Hopefully this can at least be a reference for people <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/1315" rel="bookmark" class="crp_title">Delegation via Roles</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/428" rel="bookmark" class="crp_title">Git Workflow for Rakudo</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/844" rel="bookmark" class="crp_title">YAPC::NA &#8211; Day -1: Moose</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1349" rel="bookmark" class="crp_title">DBIx::Class has migrated to git!</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1300" rel="bookmark" class="crp_title">Announcing Log::Contextual</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1344/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>How CPAN (and Open Source) works</title>
		<link>http://blog.afoolishmanifesto.com/archives/1331</link>
		<comments>http://blog.afoolishmanifesto.com/archives/1331#comments</comments>
		<pubDate>Thu, 20 May 2010 00:57:47 +0000</pubDate>
		<dc:creator>fREW Schmidt</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cpan]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1331</guid>
		<description><![CDATA[I am writing this post to address a problem that I could see appearing in our community. If it offends you feel free to let me know. If you comment on my blog as a troll, I will delete your comments. Feel free to put them on your blog where they reflect on yourself Recently [...]]]></description>
			<content:encoded><![CDATA[<p>I am writing this post to address a problem that I could see appearing in our community.  If it offends you feel free to let me know.  If you comment on my blog as a troll, I will delete your comments.  Feel free to put them on your blog where they reflect on yourself <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Recently a certain member of the community has posted a few blog posts that boil down to &#8220;Open Source developers should support their open source work as if it were a job.&#8221;  I will not make a link because I would rather people not read his posts.  Normally I feel like the best plan of action for people who make silly statements is to just ignore them, but a good friend of mine pointed out that it would be bad if people got confused and actually bought into this line of thought.</p>
<p>So in foolish manifesto style, I will write the rest of this post with how I think things <strong>should</strong> be done, not who got what wrong.</p>
<h1>Patches Welcome</h1>
<p>As a developer of CPAN modules and more tentatively a leader of a small part of CPAN, I will continue to say &#8220;Patches welcome.&#8221;  If people are using the software that I have written for CPAN they are developers and can help implement the code that they need for their given use case.  I doubt a non-developer would be able to figure out how to install a CPAN module, let alone use it.</p>
<p>Patches are not just for code though!  That is where novice developers come in.  In the <a href="http://search.cpan.org/perldoc?DBIx::Class">DBIx::Class</a> world (and I imagine <a href="http://search.cpan.org/perldoc?Catalyst">Catalyst</a> and <a href="http://search.cpan.org/perldoc?Moose">Moose</a>) standard practice is to help a newbie on IRC and then in return ask them for a documentation patch that will have rendered the help session needless.  Of course sometimes the documentation needs massaging or you need to guide the newbie as to where the documentation should go, but that&#8217;s fine!  This is how you get new blood into your contributor pool.</p>
<p>And of course the beauty of the &#8220;patches welcome&#8221; statement is that by definition only people who actually want the feature will send you patches!  I would never ask a random user of my module to implement a feature that they do not need.  It is because I needed correct sorting in SQL Server that I got involved with DBIx::Class.  I did not ask: &#8220;How can I make this happen?&#8221;  I actually asked someone else to fix it for me, and instead this person (ribasushi) guided me on how to do it myself.  To restate the point: <strong>patches should be written by the people who will use them.</strong></p>
<h1>Meritocracy</h1>
<p>One of the beauties of the open source world is that ultimately things are (to an extent) a meritocracy.  That means that the people who get stuff done have the most say.  As a Perl developer I am much more likely to listen to RJBS or Miyagawa about how to do something or even defer to them over some random developer I have never heard of.  Of course there are times when things are done democratically.  Recently some of us DBIx::Class developers had a vote about something.  <a href="http://shadowcat.co.uk/blog/matt-s-trout/iron-man-lost?colour=green&#038;title=how+perl+5+and+perl+6+will+interact+in+5+years">mst</a> has even stated to us that when it comes to DBIx::Class he is willing to defer to the other developers if everyone else agrees.  But ultimately, because writing software takes skill, the people with that skill make the decisions.  Not the people who are the prettiest or richest or have the best marketting.  I personally like it that way and will do what I can to keep it that way.</p>
<p>I say this because really, open source programming ultimately is not like regular work.  Sure, developers fall off of the face of the planet and stop maintaining their software.  But if you need the software that they wrote, you have at least two options; the first is that you contact the author and ask if you can take over the project so that you can get it back to a point where you can use it.  If that sounds like too much work you clearly do not really need it.  Your second option, if the author does not give you the OK to take over the project, is to <a href="http://oreilly.com/catalog/cathbazpaper/chapter/ch05.html#AUTOID-1631">fork</a> it.  Generally this should be avoided, since it can breed bad blood and often your software and the authors can have incompatibilities, but it is an option nonetheless.</p>
<p>I have done both of the above and it was never a huge problem.  So again, in Open Source software, the onus is on the <strong>user</strong> not the developer; but that is why I use it, personally.  If a developer dies, I as the user will be ok because I can fork the project myself.</p>
<h1>Social norms</h1>
<p>As I already said, the main reason for this post is so that developers inside and outside of the community will not be misled.  I do not want new developers using my software expecting that they can just make demands and that I will do what they ask.  I am not a hostage and neither is my software.  I do not work for free.  Anyone who expects me to work for free is either lying to themselves, insane, or is a looter stealing from me.  I do not respect the opinions of thieves, liars, or lunatics when it comes to responsibility and I do not plan to respect their opinions.</p>
<p>I strongly believe the above, and I hope that we can all have some healthy discussion about it and hopefully come to agreement.  I also have some thoughts on how to help increase the communication between various dissenters and those of us who like things the way they are, but I will leave those for another day.</p>
<h1>Update</h1>
<p>Turns out that this turned into a meme, so I&#8217;ll try to collect all of the related links to this topic here.  I&#8217;m sure that I left some out, but I tried to include all of the ones that popped up in my feed reader.  (Note: I&#8217;m <a href="http://blog.afoolishmanifesto.com/archives/1264">not subscribed</a> to all of Iron Man, so I might have missed some)</p>
<ul>
<li><a href="http://www.modernperlbooks.com/mt/2010/05/the-perlegorical-imperative-and-the-will-to-contribute.html">chromatic&#8217;s thoughts</a></li>
<li><a href="http://www.dagolden.com/index.php/804/expectations-of-volunteers-in-open-source/">dagolden&#8217;s thoughts</a></li>
<li><a href="http://chris.prather.org/patches-welcome.md.html">perigrin&#8217;s thoughts</a> </li>
<li><a href="http://jjnapiorkowski.vox.com/library/post/opensource-free-software-volunteerism-and-support-1.html">jjnapiorkowski&#8217;s thoughts</a></li>
<li><a href="http://perl-yarg.blogspot.com/2010/05/iron-man-fail-xenoterracide-is-whiny.html">nperez&#8217; thoughts</a></li>
</ul>
<div id="crp_related"><h2>Related Posts:</h2><ul><li><a href="http://blog.afoolishmanifesto.com/archives/751" rel="bookmark" class="crp_title">Contributing to Open Source</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/886" rel="bookmark" class="crp_title">Chapter 7: Open Source</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1207" rel="bookmark" class="crp_title">JAP(5|6)H</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1100" rel="bookmark" class="crp_title">How to Help without being a Rockstar</a></li><li><a href="http://blog.afoolishmanifesto.com/archives/1352" rel="bookmark" class="crp_title">Announcing DBIx::Class::DeploymentHandler</a></li><li>Powered by <a href="http://ajaydsouza.com/wordpress/plugins/contextual-related-posts/">Contextual Related Posts</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>http://blog.afoolishmanifesto.com/archives/1331/feed</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
	</channel>
</rss>
