<?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>Perlblogs &#187; Uncategorized</title>
	<atom:link href="http://perlblogs.com/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://perlblogs.com</link>
	<description>Posts from selected Perl bloggers</description>
	<lastBuildDate>Fri, 18 May 2012 19:03:44 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
<atom:link rel="hub" href="http://pubsubhubbub.appspot.com"/><atom:link rel="hub" href="http://superfeedr.com/hubbub"/>		<item>
		<title>Passing of Randy Kobes</title>
		<link>http://feedproxy.google.com/~r/PerlBuzz/~3/LVB-uS-CX-0/passing-of-randy-kobes.html</link>
		<comments>http://feedproxy.google.com/~r/PerlBuzz/~3/LVB-uS-CX-0/passing-of-randy-kobes.html#comments</comments>
		<pubDate>Tue, 09 Nov 2010 15:29:31 +0000</pubDate>
		<dc:creator>Andy Lester</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Curtis &#34;Ovid&#34; Poe forwarded to me this announcement from the University of Winnipeg about the passing of Perl community member Randy Kobes. Most Perl people will know of Randy because of his kobesearch alternative CPAN search interface. It is with...]]></description>
			<content:encoded><![CDATA[
        <p>Curtis "Ovid" Poe forwarded to me this announcement from the University of Winnipeg about the passing of Perl community member Randy Kobes.  Most Perl people will know of Randy because of his <a href="http://kobesearch.cpan.org/">kobesearch</a> alternative CPAN search interface.</p>

<blockquote>
  <p>It is with profound sadness that the University learned yesterday of the passing of Associate  Dean of Science Randy Kobes. Dr. Kobes passed away after a recent battle with  lung cancer.</p>
  
  <p>Randy was an excellent academic, physicist and educator of  young people. He was fully dedicated to public engagement in science.  His contributions to community learning at The University of Winnipeg went far beyond the classroom.</p>
  
  <p>Randy was a primary driver of the  University's Let's Talk Science and was also keenly involved in the Eco-Kids  programs, and numerous other outreach activities that involved inner-city  children and youth. He was also the leader of numerous new degree programs in  science, including Radiation Health and Safety; Science, Environment  and Indigenous Knowledge; and pre-professional programs.</p>
  
  <p>Randy was  truly dedicated to student success. Almost all of his work efforts were  directed to encouraging student success in one way or another. Along with the  many initiatives mentioned above, he volunteered his time in the summer with  the CSI (Community School Investigators), an inner city summer learning  enrichment program and was very involved in the homework club at the Wii  Chiiwaakanak Learning Centre. He also personally drove students to Sisler  High School, where the University had established an off-campus  homework club.</p>
  
  <p>Randy obtained a B. Eng. degree in Engineering Physics  from the University of Saskatchewan in 1978 and a Ph.D. in theoretical  physics from the University of Alberta in 1983. He held  postdoctoral fellowships at the University of British Columbia and at  Memorial University of Newfoundland before joining the University of  Winnipeg in 1987.</p>
  
  <p>His research interests included the application of  quantum field theoretic methods to topics in theoretical particle physics  and investigating non-linear effects using numerical techniques. He  held an NSERC Discovery Grant since joining the University of Winnipeg,  and most recently served as the University’s Associate Dean of  Science.</p>
  
  <p>In June 2005 Randy was awarded the Marsha Hanen Award for  Excellence in Creating Community Awareness. He founded the Manitoba chapter  of Let’s Talk Science, which promotes scientific literacy by having University of Winnipeg volunteer scientists visit classrooms,  present interactive experiments and raise awareness of science. In  October 1999 he won the Erica and Arnold Rogers Award for Excellence  in Research and Scholarship.</p>
</blockquote>

        

    <div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=LVB-uS-CX-0:2LRUIsTz3zc:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=LVB-uS-CX-0:2LRUIsTz3zc:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?i=LVB-uS-CX-0:2LRUIsTz3zc:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=LVB-uS-CX-0:2LRUIsTz3zc:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?i=LVB-uS-CX-0:2LRUIsTz3zc:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=LVB-uS-CX-0:2LRUIsTz3zc:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/PerlBuzz/~4/LVB-uS-CX-0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/11/09/passing-of-randy-kobes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to script git with perl and Git::Wrapper</title>
		<link>http://www.dagolden.com/index.php/998/how-to-script-git-with-perl-and-gitwrapper/</link>
		<comments>http://www.dagolden.com/index.php/998/how-to-script-git-with-perl-and-gitwrapper/#comments</comments>
		<pubDate>Tue, 31 Aug 2010 03:17:41 +0000</pubDate>
		<dc:creator>dagolden</dc:creator>
				<category><![CDATA[git]]></category>
		<category><![CDATA[ironman]]></category>
		<category><![CDATA[perl programming]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.dagolden.com/?p=998</guid>
		<description><![CDATA[If you work with git, eventually you will want to script something that git doesn't do already and can't be accomplished with an alias. If you use Perl, the Git::Wrapper module makes scripting git easy. The big advantage of Git::Wrapper is that it wraps the binary version of git, which keeps your perl and git [...]]]></description>
			<content:encoded><![CDATA[<p>If you work with <a href="http://git-scm.com/">git</a>, eventually you will want to script something that git doesn't do already and can't be accomplished with an alias.  If you use <a href="http://perl.org/">Perl</a>, the <a href="http://p3rl.org/Git%3A%3AWrapper">Git::Wrapper</a> module makes scripting git easy.</p>
<p>The big advantage of Git::Wrapper is that it wraps the binary version of git, which keeps your perl and git independent.  Upgrade perl and not git?  Add Git::Wrapper and you're done.  Upgrade git while keeping your existing perl?  No problem.  If you get your git from an OS distribution package, but <a href="http://p3rl.org/App%3A%3Aperlbrew">roll your own perl</a>, then Git::Wrapper is for you!</p>
<p>Git::Wrapper just makes it really easy to pass git commands and get back useful data.  It really shines on "git log" commands, as it parses each commit message into Git::Wrapper::Log objects with accessors for id, author, date, and message.  For everything else, it's not much more than a wrapper around qx(), but it returns arrays of lines and throws exceptions when things go wrong, which just saves a little time and code.</p>
<p>Here is a short example that I whipped up recently to automate the process of adding a <a href="http://github.com/">github</a> repository remote for someone when they send me a pull request.  (It also uses my <a href="http://p3rl.org/Getopt%3A%3ALucid">Getopt::Lucid</a> module, but as the name suggests, it should be clear what that does.)</p>
<pre class="brush: perl;">
#!/usr/bin/env perl
use 5.010;
use strict;
use warnings;
use autodie;
use Git::Wrapper;
use Getopt::Lucid qw/:all/;

# USAGE: github-remote [-r REPO] [NAME]
#     NAME -- a github user name (or defaults to 'dagolden')
#     REPO -- a github repository path (or is parsed out of my private origin repo)

my $opts = Getopt::Lucid-&gt;getopt([
  Param('repo|r'),
]);

my $who = shift @ARGV;

# Get a wrapper for the current directory
my $git = Git::Wrapper-&gt;new(&quot;.&quot;);

# Locate the origin repository URL
my ($origin) = grep { /origin/ } $git-&gt;remote(&quot;-v&quot;);
die &quot;Couldn't determine origin\n&quot; unless $origin;
$origin =~ s/^origin\s+//;
$origin =~ s/\s+\(.*$//;

# Parse out the repository path
my $repo = $opts-&gt;get_repo;
unless ( $repo ) {
  # me@git.example.com:my-repo-name.git
  ($repo) = $origin =~ m/^[^:]+:(.+)$/;
}

# Set up someone else's github repo
if ( $who ) {
  $git-&gt;remote(&quot;add&quot;, $who, &quot;git://github.com/${who}/${repo}&quot;);
}
# Or set up my own github mirror
else {
  $git-&gt;remote(&quot;add&quot;, &quot;github&quot;, &quot;git\@github.com:dagolden/${repo}&quot;);
}
</pre>
<p>That's it.  I admit the program is a little crufty because of how I manage my repositories with a private origin that I mirror to a github repository, but there's almost no cruft around interactions with git.  Consider this:</p>
<pre class="brush: perl;">
  $git-&gt;remote(&quot;add&quot;, $who, &quot;git://github.com/${who}/${repo}&quot;);
</pre>
<p>If the command fails (if there's already $who as a remote name), an exception will be thrown. That means I don't have to write any error handling myself, which is perfect for a simple automation program like this one.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.dagolden.com/index.php/998/how-to-script-git-with-perl-and-gitwrapper/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Perl is not an acronym</title>
		<link>http://feedproxy.google.com/~r/PerlBuzz/~3/ayygvBUsvu4/perl-is-not-an-acronym.html</link>
		<comments>http://feedproxy.google.com/~r/PerlBuzz/~3/ayygvBUsvu4/perl-is-not-an-acronym.html#comments</comments>
		<pubDate>Tue, 10 Aug 2010 15:11:16 +0000</pubDate>
		<dc:creator>Andy Lester</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[A reminder to those out there, especially HR folks, that the language Perl is always spelled &#34;Perl&#34; and never &#34;PERL.&#34; From the Perl FAQ: Before the first edition of Programming perl, people commonly referred to the language as &#34;perl&#34;, and...]]></description>
			<content:encoded><![CDATA[
        <p>A reminder to those out there, especially HR folks, that the language Perl is always spelled "Perl" and never "PERL."  From the <a href="http://faq.perl.org/perlfaq1.html#What_s_the_differenc">Perl FAQ</a>:</p>

<blockquote>
  <p>Before the first edition of <em>Programming perl</em>, people commonly referred to the language as "perl", and its name appeared that way in the title because it referred to the interpreter. In the book, Randal Schwartz capitalised the language's name to make it stand out better when typeset. This convention was adopted by the community, and the second edition became Programming Perl, using the capitalized version of the name to refer to the language.</p>
  
  <p>You may or may not choose to follow this usage. For example, parallelism means "awk and perl" and "Python and Perl" look good, while "awk and Perl" and "Python and perl" do not. But never write "PERL", because perl is not an acronym, apocryphal folklore and post-facto expansions notwithstanding.</p>
</blockquote>

<p>Those post-facto expansions are "Practical Expansion and Reporting Language" and "Pathologically Eclectic Rubbish Lister."  Both are bacryonms, created after the language was named.</p>

        

    <div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=ayygvBUsvu4:v1JNhmxRrZ4:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=ayygvBUsvu4:v1JNhmxRrZ4:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?i=ayygvBUsvu4:v1JNhmxRrZ4:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=ayygvBUsvu4:v1JNhmxRrZ4:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?i=ayygvBUsvu4:v1JNhmxRrZ4:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=ayygvBUsvu4:v1JNhmxRrZ4:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/PerlBuzz/~4/ayygvBUsvu4" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/08/10/perl-is-not-an-acronym/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to shuffle a list in Perl</title>
		<link>http://feedproxy.google.com/~r/PerlBuzz/~3/BxLSYp7Uxh0/how-to-shuffle-a-list-in-perl.html</link>
		<comments>http://feedproxy.google.com/~r/PerlBuzz/~3/BxLSYp7Uxh0/how-to-shuffle-a-list-in-perl.html#comments</comments>
		<pubDate>Fri, 28 May 2010 14:32:58 +0000</pubDate>
		<dc:creator>Andy Lester</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[If you've got a list of things in Perl, and you want them in random order, don't try to make up a way to do it yourself. Use the shuffle function in the List::Util module. Say you want a list...]]></description>
			<content:encoded><![CDATA[
        <p>If you've got a list of things in Perl, and you want them in random order, don't try to make up a way to do it yourself.  Use the <tt>shuffle</tt> function in the List::Util module.  Say you want a list of files from a directory:</p>

<pre>
use List::Util qw( shuffle );
my @files = glob( '*' );
@files = grep { -f } @files;
@files = shuffle @files;
</pre>

<p>Of course you can combine that into one expression:</p>

<pre>
use List::Util qw( shuffle );
my @files = shuffle grep { -f } glob( '*' );
</pre>

<p>Or from the command line:</p>

<pre>
perl -MList::Util=shuffle -le'print for shuffle grep {-f} glob("*")'
</pre>

<p>Don't worry that List::Util is a module, because it's a core module that's been included with Perl since 5.7.3</p>

<pre>
$ corelist List::Util

List::Util was first released with perl 5.007003
</pre>

<p>The <tt>shuffle</tt> function is extremely simple, and how here's a little <a href="http://eli.thegreenplace.net/2010/05/28/the-intuition-behind-fisher-yates-shuffling/">article that explains why it works</a>.</p>

        

    <div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=BxLSYp7Uxh0:khMgTBTukmo:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=BxLSYp7Uxh0:khMgTBTukmo:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?i=BxLSYp7Uxh0:khMgTBTukmo:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=BxLSYp7Uxh0:khMgTBTukmo:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?i=BxLSYp7Uxh0:khMgTBTukmo:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/PerlBuzz?a=BxLSYp7Uxh0:khMgTBTukmo:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/PerlBuzz?d=qj6IDK7rITs" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/PerlBuzz/~4/BxLSYp7Uxh0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/05/28/how-to-shuffle-a-list-in-perl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Links for 2010-05-27 [del.icio.us]</title>
		<link>http://feeds.askbjoernhansen.com/~r/ask/~3/IvRuycMdQf0/ask</link>
		<comments>http://feeds.askbjoernhansen.com/~r/ask/~3/IvRuycMdQf0/ask#comments</comments>
		<pubDate>Fri, 28 May 2010 07:00:00 +0000</pubDate>
		<dc:creator>Ask Bjørn Hansen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://del.icio.us/ask#2010-05-27</guid>
		<description><![CDATA[
Migrate Paravirtualized Xen to KVM under RHEL
]]></description>
			<content:encoded><![CDATA[<ul>
<li><a href="http://www.gloudemans.info/migrate-paravirtualized-xen-to-kvm-under-rhel/">Migrate Paravirtualized Xen to KVM under RHEL</a></li>
</ul><img src="http://feeds.feedburner.com/~r/ask/~4/IvRuycMdQf0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/05/28/links-for-2010-05-27-del-icio-us/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Anethics of Innovation and Disclosure</title>
		<link>http://www.modernperlbooks.com/mt/2010/05/the-anethics-of-innovation-and-disclosure.html</link>
		<comments>http://www.modernperlbooks.com/mt/2010/05/the-anethics-of-innovation-and-disclosure.html#comments</comments>
		<pubDate>Mon, 24 May 2010 19:35:42 +0000</pubDate>
		<dc:creator>chromatic</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Whenever someone suggests that innovation is the sine qua non of anything in the world of technology, lock your doors, put one hand on your wallet, and send the kids inside. (Me, I also close the tab and delete the...]]></description>
			<content:encoded><![CDATA[
        <p>Whenever someone suggests that innovation is the sine qua non of
<em>anything</em> in the world of technology, lock your doors, put one hand on
your wallet, and send the kids inside.  (Me, I also close the tab and delete
the email.)</p>

<p>Consider your privacy.  Consider whether a company whose sole business
purpose is to sell targeted advertising by extracting, sharing, and mining
personal information from millions of people.  (Do I mean Google or Facebook?)
A fan of free markets and free information might say "Whether any individual
finds that objectionable, an informed citizen should have the right to decide
whether to participate."</p>

<p>The assumption is that citizens should be able to know what information the
business shares, with whom, and why.  It's easy to understand why.  Even though
it's funny to laugh at a petty criminal caught by posting a stupid update which
gives the authorities reasonable suspicion of a crime, it's unsettling to
imagine an abused and estranged spouse who's dutifully followed the guidelines
for not allowing personal information to escape a hand-vetted circle of
trustworthy family and friends fall victim to an unannounced, opt-out rule
change which allows the abuser to perpetuate the abuse.</p>

<p>The parallel to Perl is subtle, but important.  <a
href="http://www.modernperlbooks.com/mt/2009/02/backwards-compatibility-is-technical-debt.html">If
you want to improve your software, sometimes you have to make incompatible
changes</a> (or learn how to predict the future, or write software so trivial
that you always get it right the first time), but <a
href="http://www.modernperlbooks.com/mt/2009/05/writing-perl-5s-support-policy.html">changing
the world out from under users is irresponsible and unethical</a>.</p>

<p>The difference between managing your privacy and safety in a world where
mass communication is cheap and easy and between having to change the use of a
long deprecated feature is vast, but in both cases there's a simple ethical
concern: retroactive and arbitrary and unannounced and forced changes are wrong.</p>

<p>That's why <a href="http://radar.oreilly.com/2010/05/my-contrarian-stance-on-facebook-privacy.html">My Contrarian Stance on Facebook and Privacy</a> is very, very wrong:</p>

<blockquote><em>[Let's] not make privacy a third rail issue, pillorying any company that makes a mistake on the privacy front. If we do that, we'll never get the innovation we need to solve the thorny nest of issues around privacy and data ownership that are intrinsic to the network era.</em></blockquote>

<p>Don't let the shiny of the Internet hero de jure fool you.  The technical world needs less "innovation".  (I'll take less of the kind of "innovation" which suggests that if I didn't want to share information publicly last month, I suddenly want to this month without you even asking.)  The technical world needs more grownups who don't get distracted by multibillion market caps, the inherent sexiness of enterprise software, and whatever His Jobs announces next week.  The technical world needs people who treat other people ethically.  If that means pillorying entities which act unethically, then so be it.</p>

        
    ]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/05/24/the-anethics-of-innovation-and-disclosure/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What I’m working on in Perl</title>
		<link>http://www.dagolden.com/index.php/773/what-im-working-on-in-perl/</link>
		<comments>http://www.dagolden.com/index.php/773/what-im-working-on-in-perl/#comments</comments>
		<pubDate>Wed, 28 Apr 2010 22:23:03 +0000</pubDate>
		<dc:creator>dagolden</dc:creator>
				<category><![CDATA[ironman]]></category>
		<category><![CDATA[perl programming]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.dagolden.com/?p=773</guid>
		<description><![CDATA[Andy just asked &#8220;What are you working on in Perl?&#8221; but rather than reply in a comment, I thought it would be a good Ironman post of my own, so here we go:

CPAN Meta Spec version 2 &#8212; I released the final spec and will soon be looking to rally toolchain developers to implement it.
CPAN [...]]]></description>
			<content:encoded><![CDATA[<p>Andy just asked <a href="http://perlbuzz.com/2010/04/what-are-you-working-on-in-perl.html">&#8220;What are you working on in Perl?&#8221;</a> but rather than reply in a comment, I thought it would be a good Ironman post of my own, so here we go:</p>
<ul>
<li>CPAN Meta Spec version 2 &#8212; I <a href="http://www.dagolden.com/index.php/759/cpan-meta-spec-version-2-released/">released the final spec</a> and will soon be looking to rally toolchain developers to implement it.</li>
<li>CPAN Testers 2.0 &#8212; I <a href="http://www.dagolden.com/index.php/743/cpan-testers-2-0-beta-test-update/">launched CPAN Testers 2.0 Beta site</a>, the eventual replacement for the current practice of sending CPAN Testers reports over email and I&#8217;m continuing to monitor it, tweak it and fix little bugs</li>
<li>Perl 5 core development &#8212; I&#8217;m scheduled to be the release-engineer for Perl 5.13.3 in July.  In addition, my goals for Perl 5.13 include getting HTTP support for CPAN clients into the core, simplifying CPAN configuration further and implementing CPAN Meta.</li>
<li>Drafting a formal description of the expectations for Perl build systems that use Build.PL.  Right now it&#8217;s only Module::Build, but it could be other things in the future.  I&#8217;ve started <a href="http://github.com/dagolden/cpan-api-buildpl">a very rough draft</a> of what cpan clients should expect Build.PL (and the resulting Build) to support.</li>
<li>Dist::Zilla &#8212; I&#8217;ve been converting my distributions over to Dist::Zilla as I work on them.  It&#8217;s a huge time saver for me (something I hope to blog about more later).  I&#8217;ve also implemented some plugins recently: <a href="http://search.cpan.org/perldoc?Dist::Zilla::Plugin::CheckExtraTests">DZP::CheckExtraTests</a>, <a href="http://search.cpan.org/perldoc?Dist::Zilla::Plugin::BumpVersionFromGit">DZP::BumpVersionFromGit</a> and <a href="http://search.cpan.org/perldoc?Dist::Zilla::Plugin::Twitter">DZP::Twitter</a></li>
<li>I <a href="http://www.dagolden.com/index.php/739/modulebuild-repository-migrated-to-git/">converted the Module::Build repository</a> to git to encourage more contributions and to make it easier to apply them.  I released a development version, <a href="http://search.cpan.org/~dagolden/Module-Build-0.36_08/">0.36_08</a>, with some recent additions.</li>
</ul>
<p>Here are several other things released to CPAN in the last couple months not mentioned above:</p>
<ul>
<li><a href="http://search.cpan.org/perldoc?File::chdir">File-chdir-0.1003</a> &#8212; maintenance release for 5.13.X</li>
<li><a href="http://search.cpan.org/perldoc?Acme::Module::Build::Tiny">Acme-Module-Build-Tiny-0.04</a> &#8212; a half-serious replacement for Module::Build</li>
<li><a href="http://search.cpan.org/perldoc?Version::Next">Version-Next-0.001</a> 	&#8211; increment module version numbers simply and correctly</li>
<li><a href="http://search.cpan.org/perldoc?ExtUtils::CBuilder">ExtUtils-CBuilder-0.2703</a> &#8212; better Windows support for MSVC</li>
<li><a href="http://search.cpan.org/perldoc?Net::Amazon::Config">Net-Amazon-Config-0.001</a> &#8212; simple utility to manage Amazon Web Services credentials</li>
<li><a href="http://search.cpan.org/perldoc?CPAN::Visitor">CPAN-Visitor-0.001</a> &#8212; generic traversal of distributions in a local CPAN  or minicpan repository</li>
<li><a href="http://search.cpan.org/perldoc?Capture::Tiny">Capture-Tiny-0.07</a> &#8212; the only output capturing program you should ever need</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.dagolden.com/index.php/773/what-im-working-on-in-perl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>State and the Syntax of Encapsulation</title>
		<link>http://www.modernperlbooks.com/mt/2010/04/state-and-the-syntax-of-encapsulation.html</link>
		<comments>http://www.modernperlbooks.com/mt/2010/04/state-and-the-syntax-of-encapsulation.html#comments</comments>
		<pubDate>Fri, 23 Apr 2010 23:32:51 +0000</pubDate>
		<dc:creator>chromatic</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[
        More and more I realize that good software design minimizes the amount of things you have to care about at any one time.  Well-designed programs take advantage of abstraction possibilities of languages and libraries to model the problem and it...]]></description>
			<content:encoded><![CDATA[
        <p>More and more I realize that good software design minimizes the amount of things you have to care about at any one time.  Well-designed programs take advantage of abstraction possibilities of languages and libraries to model the problem and its solution in the most effective way.  Well-designed languages minimize the syntactic concerns necessary to produce those abstractions.</p>

<p>I unsurprising news, the default Perl 5 object system shows its limits in that you have to think about Perl 5 reference syntax <em>and</em> objects <em>and</em> encapsulation, genericity, abstraction, and polymorphism all at once.  <a href="http://www.modernperlbooks.com/mt/2010/01/subtle-encouragement-toward-correctness.html">Moose encourages people to do the right thing</a> by providing abstractions that encapsulate the concerns of other levels of abstraction.  Inside-out objects did something similar.</p>

<p>I realized this yesterday when writing about <a
href="http://perldoc.perl.org/functions/state.html">the <code>state</code>
feature introduced in Perl 5.10</a>.  If you're a fan of minimalist languages
which provide one and only one obvious way to do things, you'll hate this
explanation, but at least you'll know why you're wrong.</p>

<p><code>state</code> declares a lexical variable which maintains its state
even after control flow leaves its lexical scope.  In other words, these two
snippets of code are almost entirely equivalent:</p>

<pre><code>
# the closure approach
{
    my $count = 0;

    sub add_user
    {
        my ($user, %data) = @_;
        $data{user_id}    = $count++;
        ...
    }
}

# the state approach
use feature 'state';

sub add_user
{
    state $count      = 0;

    my ($user, %data) = @_;
    $data{user_id}    = $count++;
    ...
}</code></pre>

<p>The one potential difference is that the initialization of
<code>$count</code> in the first example must take place before the first call
to <code>add_user()</code>.</p>

<p>If you're careful to avoid that tiny potential trap, you can achieve the
same effect with the closure code.  Scheme and Python and even Java fans
rejoice for a moment.  Okay, that's long enough.</p>

<p>The problem is that&mdash;just as with arguing that you don't need <code>fold</code> because you have a <code>for</code> loop with iteration&mdash;that line of thinking ignores the fact that the syntactic overhead necessary to make the former example work is too high.  Adding a single keyword to achieve the same semantics <em>and</em> avoid that tiny little trap also makes the resulting code more expressive.  It's more declarative.</p>

<p>There's nothing wrong with the goal of a language with a minimal feature
set.  That's a fine goal, but it can't be the most important goal, and it can't
be a goal in isolation.  That's because sometimes adding a feature lets you
remove unnecessary scaffolding.</p>

<p>I believe that <a href="http://www.modernperlbooks.com/mt/2009/04/attributes-of-elegant-perl-concision.html">it's better to pursue concision than artificial simplicity</a> in program and language design.</p>

        
    ]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/04/24/state-and-the-syntax-of-encapsulation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Thing about Volunteers and Civility</title>
		<link>http://www.modernperlbooks.com/mt/2010/04/the-thing-about-volunteers-and-civility.html</link>
		<comments>http://www.modernperlbooks.com/mt/2010/04/the-thing-about-volunteers-and-civility.html#comments</comments>
		<pubDate>Wed, 21 Apr 2010 20:46:34 +0000</pubDate>
		<dc:creator>chromatic</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[
        The thing about volunteers is that they don't have to do what they're doing.  If you're getting paid to hang out in an IRC channel and answer questions all day, that's one thing.  If you're hanging out on an IRC channel all day because you wan...]]></description>
			<content:encoded><![CDATA[
        <p>The thing about volunteers is that they don't have to do what they're doing.  If you're getting paid to hang out in an IRC channel and answer questions all day, that's one thing.  If you're hanging out on an IRC channel all day because you want to, that's another.</p>

<p>The thing about volunteers writing software is that they don't have to do it.  The same goes for volunteers writing documentation or reporting bugs or asking questions about how to use or install or configure that software.</p>

<p>The thing about the Perl community is that almost no one gets paid solely for participating in the Perl community.  Sure, you can volunteer for a while to earn the cachet and the right to apply for a TPF grant at a fraction of the going consulting rate to justify continuing to work on the unpleasant parts of a project, but you're still effectively a volunteer.</p>

<p>The thing about volunteers is if it's not worth their time or energy or health or sanity or happiness to keep volunteering, they can walk away whenever they want.  They have no obligation to continue to do what they do.  Not even their sense of devotion or duty or guilt or community camaraderie should compel them to continue on projects that aren't worth their investment of time, and that's more than okay.</p>

<p>The thing about volunteers is that you can't force them to do anything.  You can't force them to have your priorities.  You can't force them to work to your schedule.  You can't force them to work on your project and you can't force them to care about what you care about.  They'll do what they want to do when they want to do it and you either deal with it or you don't.</p>

<p>The thing about volunteers is that it's rare to have too many and it's far too common to have far too few.  Thus healthy projects spend time and effort recruiting volunteers and keeping volunteers around and guiding the interests and energy and time of volunteers in productive ways, not only by making their projects pleasant and useful but by removing distractions and unpleasantness from their communitites.</p>

<p>The thing about volunteers is that for every one willing to take the abuse and hostility from a few people, you can't tell how many orders of magnitude more potential volunteers find that hostility and abuse so distasteful that they refuse to consider the possibility that it's worth their time to contribute.</p>

<p>The thing about volunteers is that if you allow certain parts of the community to fester and to grow toxic, you're well on your way to having fewer and fewer volunteers who grow more bitter and eventually become a tiny little cluster of angry, angry people who can't do anything productive.</p>

<p>The thing about volunteers is that it doesn't have to be this way.</p>

<p>Certain Perl IRC channels don't have to be seething cauldrons of rage from burned out system administrators who castigate anyone who doesn't know the secret rituals and wordings of arcane rituals to identify themselves as insiders.</p>

<p>Certain Perl forums don't have to devolve into arguments over whose web framework stole which idea from some other place, or whether it's clear that anyone who does or does not use one CPAN dependency or another has parents with specific unpleasant characteristics.</p>

<p>Certain Perl mailing lists don't have to debate whether people who work on one version of Perl or another are hateful fools whose only goal in life is to destroy everything good and sunshiney and organic.</p>

<p>Certain Perl blogs don't have to have comments accusing other volunteers of being liars or thieves or people of negotiable affection because said volunteers disagree on project management styles.</p>

<p>I suppose it's easier to destroy than to create, and it's easier to prove that you're right by demonstrating your scathing verbal wit with a keyboard, and it's easier to believe that you've won an argument if you reduce the other person to a cardboard cutout of simplistic, ridiculous beliefs.  It's also easy to justify your decision to spread hostility if you can overlook the fact that the person you're castigating is a human being with complex motivations, goals, dreams, aspirations, beliefs, and emotions.</p>

<p>The thing about volunteers is that they don't owe you a thing.</p>

<p>If you want a Perl community full of hostile people who jump to hasty conclusions, who are willing to nitpick and debate the specific meaning of words than to understand what other people mean, and who are willing to throw wild accusations of crazy, hateful motives around, then you have an easy task.  Just say nothing.  Let it fester.</p>

<p>Me, I don't think that's the way to encourage a healthy community.  After
all, how silly is it to argue over how some other volunteer spends his or her
time?  Yet isn't that what we're doing?</p>

<p>Maybe if more of us speak up when we see this abuse and hostility, maybe we can discourage it.  Maybe we can encourage people to try to understand and listen more, or at least to disagree politely if they must disagree.  Maybe we can help people unwilling to be civil to find better hobbies than abusing other volunteers.   Maybe we can make the Perl community and our IRC channels and our mailing lists and our forums and our comment sections places where potential volunteers <em>want</em> to participate because they know that we appreciate novices and we appreciate volunteers and we don't all have to do the same things or want the same things or agree on the same things to treat each other with respect.</p>

<p>After all, we're all trying to build great software to solve problems.  Why should we borrow trouble?</p>

        
    ]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/04/21/the-thing-about-volunteers-and-civility/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Three-arg open() (Migrating to Modern Perl)</title>
		<link>http://www.modernperlbooks.com/mt/2010/04/three-arg-open-migrating-to-modern-perl.html</link>
		<comments>http://www.modernperlbooks.com/mt/2010/04/three-arg-open-migrating-to-modern-perl.html#comments</comments>
		<pubDate>Mon, 19 Apr 2010 21:55:07 +0000</pubDate>
		<dc:creator>chromatic</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[
        I can forgive novices for writing clunky Perl code because they're following the example of far too many books and tutorials.  If you date the Perl Renaissance to the year 2000 (as I do), then you can identify code written before that point an...]]></description>
			<content:encoded><![CDATA[
        <p>I can forgive novices for writing clunky Perl code because they're following the example of far too many books and tutorials.  If you date the <a href="http://www.modernperlbooks.com/mt/2009/07/milestones-in-the-perl-renaissance.html">Perl Renaissance</a> to the year 2000 (as I do), then you can identify code written before that point and code written after that point.</p>

<p><em>If</em> modern Perl is safer or easier or clearer or simpler or cleaner to write than legacy Perl, then it should be possible to explain how and why to use modern features in lieu of older features.</p>

<p>For example....</p>

<h2><strong>Three-argument <code>open()</code></strong></h2>

<p>There are two forms of the <code>open()</code> function in Perl 5.  The modern version takes three arguments: the filehandle to open or vivify, the mode of the filehandle, and the name of the file.</p>

<p>The legacy version has two arguments, only the filehandle and the name of the file.  The mode of the file comes from the filename; if the filename starts (or ends) with any of several special characters, <code>open()</code> parses them off and uses them.</p>

<p>If you accidentally use a filename with those special characters with the
two-arg form of <code>open()</code>, your code will not behave as you expect.
This is especially a problem if you're not careful about sanitizing user input,
and if any user input ever becomes part of a filename.  Consider:</p>

<pre><code>open my $fh, "&gt;$filename" # INSECURE CODE; do not use
    or die "Can't write to '$filename': $!\n";</code></pre>

<p>While this code appears to open <code>$filename</code> for writing, an
insecure <code>$filename</code> could start with <code>&gt;</code> to force
appending mode, or <code>-</code> to open STDOUT (though I suspect you have to
work really hard to force this).  Likewise, code without any explicit mode in
the second and final parameter is susceptible to any special mode
characters.</p>

<p>Extracting file modes into a separate parameter to this function prevents
Perl from parsing the filename at all and removes the possibility for this
unintentional behavior.  As Damian Conway has mentioned, using a separate file
mode parameter also makes the intention of the code clearer:</p>

<pre><code>open my $fh, '&gt;', $filename # safer and clearer
    or die "Can't write to '$filename': $!\n";</code></pre>

<p>The modern version of this code is safer and clearer, and it's been
available since Perl 5.6.0, released on 22 March 2000.  There's no reason not
to use the modern version.  (If you need your code to run on Perl 5.005, try a
core module such as <a
href="http://search.cpan.org/perldoc?IO::Handle">IO::Handle</a>.  If you need
your code to run on older versions of Perl 5, you have my sympathy.)</p>
        
    ]]></content:encoded>
			<wfw:commentRss>http://perlblogs.com/2010/04/19/three-arg-open-migrating-to-modern-perl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

