BooK's Journal http://use.perl.org/~BooK/journal/ BooK's use Perl Journal en-us use Perl; is Copyright 1998-2006, Chris Nandor. Stories, comments, journals, and other submissions posted on use Perl; are Copyright their respective owners. 2012-01-25T01:46:14+00:00 pudge pudge@perl.org Technology hourly 1 1970-01-01T00:00+00:00 BooK's Journal http://use.perl.org/images/topics/useperl.gif http://use.perl.org/~BooK/journal/ Flore Louise Apolline Bruhat-Souche http://use.perl.org/~BooK/journal/40510?from=rss <p>On Thursday, August 19, 2010 at 9:30, Flore Louise Apolline Bruhat-Souche was born. She weighs 3.02 kg and measures 48 cm. </p><p> Word already spread through IRC (#perlfr and #yapc mostly) and via email and telephone. </p><p> The mother is fine, the father is slightly tired and the <a href="http://use.perl.org/~BooK/journal/33509">big sister</a> is happy. </p><p> There is <a href="http://flore.bruhat-souche.net/">one photo online</a>. </p> BooK 2010-08-20T22:17:07+00:00 journal Fixing Mailman with Perl http://use.perl.org/~BooK/journal/40266?from=rss <p>Mailman is useful. Mailman works. Mailman is ubiquitous. I am subscribed to over 50 mailing-lists managed by Mailman.</p><p> But Mailmand is software, and therefore <a href="http://hates-software.com/">hateful</a>. </p><p>My particular Mailman hate is the <code>nodupes</code> parameter.</p><blockquote><div><p> <i> <b>Avoid duplicate copies of messages?</b> </i> </p><p> <i>When you are listed explicitly in the To: or Cc: headers of a list message, you can opt to not receive another copy from the mailing list. Select Yes to avoid receiving copies from the mailing list; select No to receive copies.</i> </p><p> <i>If the list has member personalized messages enabled, and you elect to receive copies, every copy will have a X-Mailman-Copy: yes header added to it.</i> </p></div> </blockquote><p>I like duplicate email. Moreover, I like the <code>List-Id</code> header that makes emails sent through a list <i>special</i> (at least in the sense that they can be filtered <i>automatically</i> by more tools, and I can just delete the stuff that piles up in my Inbox). And by the way, how could Mailman be really sure that I got that other copy? Just because the headers say so? Bah.</p><p>Oh, and I also hate the fact that <i>Set globally</i> never worked for me with this option.</p><p>So, because I'm lazy, and I don't want to go clikety-click to first, get a reminder of the random password that was assigned to me years ago, and two, login and change that annoying option, and because <b>I don't want to do that fifty times, over and over again</b>...</p><p> I wrote and put on CPAN <a href="http://search.cpan.org/dist/WWW-Mailman/">WWW::Mailman</a>, designed to automate that kind of tedious task out of my life (and hopefully yours). Examples included, I know you're lazy too. </p><p><small>PS: I've been told there <i>is</i> a command-line interface to Mailman, but it is reserved to people managing Mailman on the server.</small></p> BooK 2010-03-25T01:07:02+00:00 journal Pink stinks http://use.perl.org/~BooK/journal/40076?from=rss <p>I still like wearing pink T-shirts, though. And not just at Perl conferences. (My love of pink basically comes from pushing a "joke" from the YAPC Europe 2002 auction way beyond its scope.)</p><p>Some very interesting reads:</p><ul> <li> <a href="http://www.guardian.co.uk/theguardian/2009/dec/12/pinkstinks-the-power-of-pink">http://www.guardian.co.uk/theguardian/2009/dec/12/pinkstinks-the-power-of-pink</a> </li><li> <a href="http://www.pinkstinks.co.uk/">http://www.pinkstinks.co.uk/</a> (I bought the T-shirt and buttons)</li><li> <a href="http://pinkstinks.wordpress.com/">http://pinkstinks.wordpress.com/</a> (the blog)</li></ul><p>A little more than a week ago, it was the second Christmas of my daughter... I guess it shows. Raising children brings all kinds of new interesting issues and questions to one's attention.</p> BooK 2010-01-05T00:35:05+00:00 journal git-move-dates http://use.perl.org/~BooK/journal/40024?from=rss <p>As a Perl programmer and Open Source enthousiast, you probably sometimes contribute to Open Source projects. Maybe even (gasp!) during work hours. If your employer is jealous of your time, you probably do not want your commits to <i>look</i> like they were done during work hours (especially in tools like the GitHub Punch Card).</p><p>On the other hand, it doesn't make sense to not commit your changes, and lose the benefits of using Git, just so that the reality of <i>when</i> you worked on these tiny changes is not made public. (At that point, it would probably also make more sense to have an open discussion with your boss...)</p><p>The way Git handles history makes it really easy to change the date of commits on a local branch. When I first thought about it, my idea was to write some date manipulation code (move a bunch of commits from a time range to another with all kinds of fancy nooks and crannies) and manipulate the Git trees and commits myself.</p><p>Then I discovered <b>git filter-branch</b>, which is all about rewriting commits. And I realized that in the situation above, moving commits a few hours in the future (like ten minutes before actually using <b>git push</b> or <b>git send-email</b>) is largely sufficient.</p><p>The problem is that the code to move a bunch of commits one hour in the future looks like this:</p><blockquote><div><p> <tt>&nbsp; &nbsp; git filter-branch --commit-filter '\<br>&nbsp; &nbsp; &nbsp; GIT_AUTHOR_DATE=`echo "$GIT_AUTHOR_DATE"|perl -pe'\''s/\d+/$&amp;+3600/e'\''`;\<br>&nbsp; &nbsp; &nbsp; GIT_COMMITTER_DATE=`echo "$GIT_COMMITTER_DATE"|perl -pe'\''s/\d+/$&amp;+3600/e'\''`;\<br>&nbsp; &nbsp; &nbsp; git commit-tree "$@"' -- &lt;rev-list&gt;</tt></p></div> </blockquote><p>Which is impossible to remember, and painful to write.</p><p>So, lazy as a Perl programmer should be, I just wrote <b>git-move-dates</b>, that writes and runs the above type of command-lines for me. Useful options include <i>--committer</i> and <i>--author</i> (to change only one of the two existing dates), and options ranging from <i>--seconds</i> to <i>--weeks</i> to define the exact timespan of your commits' time-travels.</p><p>As with my other Git gadgets, the source is available from <a href="http://github.com/book/git-gadgets">http://github.com/book/git-gadgets</a>.</p><p>And remember: there's nothing wrong with rewriting history, as long as it's <i>unpublished</i>, local history.<nobr> <wbr></nobr><code>;-)</code> </p> BooK 2009-12-15T22:22:40+00:00 journal More Git gadgets http://use.perl.org/~BooK/journal/39970?from=rss <p>Last week on p5p, after noticing that the new way to name version tags in perl5.git was to use <b>v<i>$version</i> </b>, I proposed to copy the old <b>perl-<i>$version</i> </b> tags to the new scheme, going back at least to 5.6.0 (which is when the Perl naming convention for version changed). I haven't done it yet for various reasons, but in order to do it, I developped a small <b>git-copytag</b> tool, that copies (or moves) the tag with all its annotations. Clone it from <a href="http://github.com/book/git-gadgets">http://github.com/book/git-gadgets</a>.</p><p>I also started to check if the existing tags in perl5.git point to the commit matching the published distribution, but my first attempt failed miserably (creating Git <code>tree</code> objects from the distributions and trying to find a commit pointing to the same <code>tree</code> id). I'll move on to a different approach (<code>diff -r</code>, basically).</p><p> In other news, I finally succeeded in creating the <a href="/~BooK/journal/39919">Git fractals</a> I wanted. I'll soon post more details about it on the <a href="http://philippe.bruhat.net/stuff/git-fractals/sierpinski.html">page dedicated to Sierpi&#324;ski triangles</a> on <a href="http://philippe.bruhat.net/">my personal site</a>.</p> BooK 2009-12-03T08:55:03+00:00 journal git-mtime http://use.perl.org/~BooK/journal/39932?from=rss <p>Ever complained that on a checkout Git did not reset the <code>mtime</code> of your files to the date when they were commited?</p><p> My <a href="http://philippe.bruhat.net/">home page</a> is generated with Template Toolkit but a script stored in the <tt>post-receive</tt> hook. On a checkout Git only updates the files that have changed, so normally I can trust <tt>template.modtime</tt> to be correct and use it to show a <i>Last mofidied</i> date. </p><p>But I'm a perfectionist, and I want to be extra sure. So I created this little utility, that I called <b>git-mtime</b>:</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/bin/sh<br>&nbsp; &nbsp; git log --name-only --date=iso --reverse --pretty=format:%at "$@" \<br>&nbsp; &nbsp; | perl -00ln -e '($d,@f)=split/\n/;$d{$_}=$d for grep{-e}@f' \<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;-e '}{utime undef,$d{$_},$_ for keys%d'</tt></p></div> </blockquote><p>Note that it passes all parameters to <code>git log</code>, so you can apply it on a subdirectory (using <code>--</code>), or even use the dates from another branch (though I'm not sure what use this can have).</p><p> <small>And for extra bonus points, it uses the secret eskimo greeting operator!</small> </p><p>Now that I have a few gadgets based on Git, I thought I might as well publish them somewhere. A quick look on Github ruled out <b>git-tools</b>, <b>git-utils</b> and <b>git-extras</b> (come on people, most of these things could be done with Git aliases!). <b>git-aid</b> (especially the plural) didn't seem like a good name either. So after looking around for synonyms, I settled on <b>git-gadgets</b>.</p><p>Clone it from <a href="http://github.com/book/git-gadgets">http://github.com/book/git-gadgets</a>.</p> BooK 2009-11-23T12:41:17+00:00 journal Git fractals http://use.perl.org/~BooK/journal/39919?from=rss <p> Last week (November 11) over dinner in Amsterdam, I talked with a colleague about Git as a tool for creating graphs. For some reason I started to think about a <a href="http://en.wikipedia.org/wiki/Sierpinski_triangle">Sierpir&#324;ski triangle</a>, and we started trying to create such graphs with Git. </p><p>The basic shape is a triangle (in the UTF-8 drawing below, the arrows represent the parent &#8594; child relationship):</p><p> <code>&nbsp;&nbsp;&nbsp;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;</code> </p><p>It is quite easy to create by hand. I did it using <code>git commit-tree</code>, using always the same tree object (the empty tree), as we only care about the graph that represents commit lineage, not about the content.</p><p>The next step basically repeats the same shape, attached to the low-level nodes / commits of the previous graph:</p><p> <code>&nbsp;&nbsp;&nbsp;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;</code> </p><p>I could create it in a couple of minutes, with a few more <code>git commit-tree</code> commands.</p><p>After that, it stops being interesting to do by hand, and one wants to program it. My goal has been to create the following shape, and larger ones, using a Perl program.</p><p> <code>&nbsp;&nbsp;&nbsp;A<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;<br> &nbsp;&nbsp;B&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#8901;&nbsp;C<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp; <br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#8901;</code> </p><p>Until now, I've been trying several recursive approaches, and failed miserably each time. The big issue is the merge points, showed in the graph above using &#215;.</p><p>In my recursive approaches, I usually first created the triangle (ABC), usually and then started again from B and then C. But the last merge of B (the &#215; in the middle of the bottom line) can only be created once the vertical line starting from C has been started. I should probably keep state in some way, but haven't had much time to spend on this.</p><p> I also thought about using the mapping from <a href="http://en.wikipedia.org/wiki/Pascal's_triangle">Pascal's triangle</a> (odd numbers as dots and even numbers as empty space, see both Wikipedia pages for details), but haven't actually tried it yet. </p><p> In other news, I've started to take care of my personal web site again. <a href="http://web.archive.org/web/20071217011738/http://www.bruhat.net/">It hadn't been touched since 2002</a>, so <a href="http://philippe.bruhat.net/">I gave it a facelift</a>. Surprisingly enough, the only section yet is about <a href="http://philippe.bruhat.net/stuff/git-fractals/">Git fractals</a>.<nobr> <wbr></nobr><code>;-)</code> Links to Git repositories, GraphViz images and more successful attempts with other fractals are also available there. </p> BooK 2009-11-20T00:43:58+00:00 journal git-dot http://use.perl.org/~BooK/journal/39887?from=rss <p>I'm currently experimenting with creating graphs using Git... I'm not using historical data, or even data at all (I'll soon know the SHA1 of the empty tree by heart), just nodes with <code>%s</code> as their label (I have yet to find a use for the rest of the metadata).</p><p> <b>gitk</b> is nice to look at historical information, but not so good for graphs. On the other hand, GraphViz is great for showing graphs.</p><p>What's best than Perl (and a tiny wrapping of shell on top) to produce graphs?</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/bin/sh<br>&nbsp; &nbsp; # create a good looking graph with dot<br>&nbsp; &nbsp; echo "digraph G {"<br>&nbsp; &nbsp; git log --pretty=format:"%h %p" $* \<br>&nbsp; &nbsp; | perl -lna&nbsp; -e 'print qq("$F[0]";),map{qq("$_"-&gt;"$F[0]";)}@F[1..$#F]'<br>&nbsp; &nbsp; echo "}"</tt></p></div> </blockquote><p>The output of this is usually boring, so just but pipe it to <code>dot -Tpng -ograph.png</code> and watch the pretty pictures.</p><p>Also, imagine a graph that has a full filesystem attached to each node. This is exactly the kind of stuff that Git can give us.</p><p>Not that I have any idea what this could be used for...</p> BooK 2009-11-12T16:50:11+00:00 journal nopaste http://use.perl.org/~BooK/journal/39862?from=rss <p>Just a quick post to show off a small and useful script I use whenever I need to "nopaste" some text or code:</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/usr/bin/perl -w<br>&nbsp; &nbsp; use strict;<br>&nbsp; &nbsp; use WWW::Mechanize;<br>&nbsp; &nbsp; use Getopt::Long;<br> <br>&nbsp; &nbsp; my %SITE = (<br>&nbsp; &nbsp; &nbsp; &nbsp; snit&nbsp; =&gt; 'http://nopaste.snit.ch/',<br>&nbsp; &nbsp; &nbsp; &nbsp; scsys =&gt; 'http://paste.scsys.co.uk/',<br>&nbsp; &nbsp; );<br> <br>&nbsp; &nbsp; my %CONF = (<br>&nbsp; &nbsp; &nbsp; &nbsp; channel =&gt; '',<br>&nbsp; &nbsp; &nbsp; &nbsp; nick&nbsp; &nbsp; =&gt; '',&nbsp; &nbsp; &nbsp; &nbsp;# use your own<br>&nbsp; &nbsp; &nbsp; &nbsp; summary =&gt; '',<br>&nbsp; &nbsp; &nbsp; &nbsp; paste&nbsp; &nbsp;=&gt; '',<br>&nbsp; &nbsp; &nbsp; &nbsp; site&nbsp; &nbsp; =&gt; 'snit',<br>&nbsp; &nbsp; &nbsp; &nbsp; list&nbsp; &nbsp; =&gt; '',<br>&nbsp; &nbsp; );<br> <br>&nbsp; &nbsp; GetOptions( \%CONF, 'lang=s', 'nick=s', 'summary|desc=s', 'paste|text=s',<br>&nbsp; &nbsp; &nbsp; &nbsp; 'list!', 'site=s' )<br>&nbsp; &nbsp; &nbsp; &nbsp; or die "Bad options";<br> <br>&nbsp; &nbsp; die "No such paste site: $CONF{site}\nValid choices: @{[keys %SITE]}\n"<br>&nbsp; &nbsp; &nbsp; &nbsp; if !exists $SITE{ $CONF{site} };<br> <br>&nbsp; &nbsp; my $m = WWW::Mechanize-&gt;new;<br>&nbsp; &nbsp; $m-&gt;get( $SITE{ $CONF{site} } );<br>&nbsp; &nbsp; die $m-&gt;res-&gt;status_line unless $m-&gt;success;<br> <br>&nbsp; &nbsp; if ( $CONF{list} ) {<br>&nbsp; &nbsp; &nbsp; &nbsp; print "Possible channels for $CONF{site}:\n",<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; map {"- $_\n"} grep $_,<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $m-&gt;current_form()-&gt;find_input('channel')-&gt;possible_values;<br>&nbsp; &nbsp; &nbsp; &nbsp; exit;<br>&nbsp; &nbsp; }<br> <br>&nbsp; &nbsp; unless ( $CONF{paste} ) {<br>&nbsp; &nbsp; &nbsp; &nbsp; $CONF{summary} ||= $ARGV[0] || '-';<br>&nbsp; &nbsp; &nbsp; &nbsp; $CONF{paste} = join "", &lt;&gt;;<br>&nbsp; &nbsp; }<br> <br>&nbsp; &nbsp; delete @CONF{qw( site list )};<br>&nbsp; &nbsp; $m-&gt;set_fields(%CONF);<br>&nbsp; &nbsp; $m-&gt;submit;<br>&nbsp; &nbsp; die $m-&gt;res-&gt;status_line unless $m-&gt;success;<br> <br>&nbsp; &nbsp; print +( $m-&gt;links )[0]-&gt;url, "\n";</tt></p></div> </blockquote><p>Since it works has a filter, I can call it from vim or pipe to it. It also works with a file parameter, which is used to set the paste title.</p><p>Just before posting this, I looked again on CPAN, and found the follwing:</p><ul> <li> <p> <b>App::NoPaste</b>: Seems really complete. But does much more than I need, and I like depending only on WWW::Mechanize for such tools.</p></li><li> <p> <b>WWW::Rafb</b>: Well, in an earlier version my script worked with rafb.net, but the site itself is down.</p></li><li> <p> <b>WWW::PasteBin</b>: Such a huge collection of distributions, I wouldn't which to install first.</p></li><li> <p> <b>WebService::NoPaste</b>: Found it years ago when looking for a nopaste utility, but I preferred to write my own.</p></li></ul><p>Clearly, there is no lack of modules to nopaste stuff, so I'm not going to add my own to the list.<nobr> <wbr></nobr><code>:-)</code> </p><p>I tried publishing scripts on CPAN, but I feel the toolchain is not really targetting scripts, anyway. Anyway, I have a few utility scripts like the above lying around, and I'm thinking maybe the best way to go with them nowadays is to just publish them on GitHub. Might happen someday.</p> BooK 2009-11-08T16:34:56+00:00 journal buildperl.pl http://use.perl.org/~BooK/journal/39818?from=rss <p>I'm trying to compile a bunch of old perls to test my modules against them. I started with 5.8.9, and it went like this:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $ git checkout -f perl-5.8.9<br>&nbsp; &nbsp; [git output]<br>&nbsp; &nbsp; $ git clean -xdf<br>&nbsp; &nbsp; [more git output]<br>&nbsp; &nbsp; $ sh Configure -Dprefix=/opt/perl/5.8.9 -des -Uinstallusrbinperl<br>&nbsp; &nbsp; [Configure output]<br>&nbsp; &nbsp; $ make &amp;&amp; make test &amp;&amp; make install<br>&nbsp; &nbsp; [make output]<br>&nbsp; &nbsp; [test output]<br>&nbsp; &nbsp; [install output]</tt></p></div> </blockquote><p>And, ta-da! After less than 15 minutes, Perl 5.8.9 was in<nobr> <wbr></nobr><i>/opt/perl/</i>, ready to be used.</p><p>Encouraged by this, I went on to compile 5.8.8. I was a bit disappointed when the same procedure (after a <code>s/5.8.8/5.8.9/g</code>) failed with:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $ sh Configure -Dprefix=/opt/perl/5.8.8 -des -Uinstallusrbinperl<br>&nbsp; &nbsp; [Configure output]<br>&nbsp; &nbsp; Run make depend now? [y]<br>&nbsp; &nbsp; sh<nobr> <wbr></nobr>./makedepend MAKE=make<br>&nbsp; &nbsp; make[1]: Entering directory `/data/home/book/src/ext/perl'<br>&nbsp; &nbsp; sh writemain lib/auto/DynaLoader/DynaLoader.a&nbsp; &gt; perlmain.c<br>&nbsp; &nbsp; rm -f opmini.c<br>&nbsp; &nbsp; cp op.c opmini.c<br>&nbsp; &nbsp; echo&nbsp; av.c scope.c op.c doop.c doio.c dump.c hv.c mg.c reentr.c perl.c perly.c pp.c pp_hot.c pp_ctl.c pp_sys.c regcomp.c regexec.c utf8.c gv.c sv.c taint.c toke.c util.c deb.c run.c universal.c xsutils.c pad.c globals.c perlio.c perlapi.c numeric.c locale.c pp_pack.c pp_sort.c miniperlmain.c perlmain.c opmini.c | tr ' ' '\n' &gt;.clist<br>&nbsp; &nbsp; make[1]: Leaving directory `/data/home/book/src/ext/perl'<br>&nbsp; &nbsp;<nobr> <wbr></nobr>./makedepend: 1: Syntax error: Unterminated quoted string<br>&nbsp; &nbsp; make: *** [depend] Error 2<br> <br>&nbsp; &nbsp; If you compile perl5 on a different machine or from a different object<br>&nbsp; &nbsp; directory, copy the Policy.sh file from this object directory to the<br>&nbsp; &nbsp; new one before you run Configure -- this will help you with most of<br>&nbsp; &nbsp; the policy defaults.</tt></p></div> </blockquote><p>In the past, I had tried to compile older Perls, and S&#233;bastien Aperghis-Tramoni had pointed me to a few patches he had made to be able to compile 5.004_05 with a more recent (3.x) gcc.</p><p>So, by looking at his patch again and the output of <code>git diff perl-5.8.8 perl-5.8.9 -- makedepend.SH</code> I was able to produce a patch, that looked exactaly like S&#233;bastien's patches for 5.004_05. The <code>Configure</code> step now worked!</p><p>But then it's the compilation phase that failed:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $ make<br>&nbsp; &nbsp; [make output]<br>&nbsp; &nbsp; &nbsp; &nbsp; Making IPC::SysV (dynamic)<br>&nbsp; &nbsp; Checking if your kit is complete...<br>&nbsp; &nbsp; Looks good<br>&nbsp; &nbsp; Writing Makefile for IPC::SysV<br>&nbsp; &nbsp; make[1]: Entering directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; make[1]: Leaving directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; make[1]: Entering directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; cp Msg.pm<nobr> <wbr></nobr>../../../lib/IPC/Msg.pm<br>&nbsp; &nbsp; cp Semaphore.pm<nobr> <wbr></nobr>../../../lib/IPC/Semaphore.pm<br>&nbsp; &nbsp; cp SysV.pm<nobr> <wbr></nobr>../../../lib/IPC/SysV.pm<br>&nbsp; &nbsp;<nobr> <wbr></nobr>../../../miniperl "-I../../../lib" "-I../../../lib"<nobr> <wbr></nobr>../../../lib/ExtUtils/xsubpp&nbsp; -typemap<nobr> <wbr></nobr>../../../lib/ExtUtils/typemap&nbsp; SysV.xs &gt; SysV.xsc &amp;&amp; mv SysV.xsc SysV.c<br>&nbsp; &nbsp; cc -c&nbsp; &nbsp;-fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2&nbsp; &nbsp;-DVERSION=\"1.04\" -DXS_VERSION=\"1.04\" -fpic "-I../../.."&nbsp; &nbsp;SysV.c<br>&nbsp; &nbsp; SysV.xs:7:25: error: asm/page.h: No such file or directory<br>&nbsp; &nbsp; make[1]: *** [SysV.o] Error 1<br>&nbsp; &nbsp; make[1]: Leaving directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; make: *** [lib/auto/IPC/SysV/SysV.so] Error 2</tt></p></div> </blockquote><p>This looked a bit trickier. Luckily, Google informed me that the <i>asm/page.h</i> file had moved in the Linux tree. Using git again, I looked for changes involving <code>page.h</code>. The changes were a lot bigger, and harder for me to understand.</p><p>By chance, the first interesting diff I found was for a change in <i>ext/Devel/PPPort/devel/buildperl.pl</i>. Wow, this looked exactly like the tool I needed to, erm, <i>build perl</i>.</p><p>So instead of adding complexity to my home-made perl-building script by adding more cases where a patch was necessary, I tried my hand at patching <b>buildperl.pl</b> to make it support newer gcc versions than the ones that existed at the time the older perls were written.</p><p>Looking for the proper patches with git is extremely easy, and I was quickly able to find the necessary patches. The longer part was to actually compile all Perls from 5.6.0 to 5.9.5.<nobr> <wbr></nobr><code>:-)</code> </p><p>Since buildperl.pl works with perl archives, my test script ended up like this:</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/bin/sh<br> <br>&nbsp; &nbsp; # blead has my local patch<br>&nbsp; &nbsp; git checkout blead<br>&nbsp; &nbsp; git clean -xdf<br> <br>&nbsp; &nbsp; # setup temporary directories<br>&nbsp; &nbsp; rm<nobr> <wbr></nobr>/tmp/buildperl.log<br>&nbsp; &nbsp; rm -rf<nobr> <wbr></nobr>/tmp/perl<br>&nbsp; &nbsp; mkdir<nobr> <wbr></nobr>/tmp/perl<br>&nbsp; &nbsp; mkdir<nobr> <wbr></nobr>/tmp/perl/source<br> <br>&nbsp; &nbsp; # compile and test all the tags given on command-line<br>&nbsp; &nbsp; for tag in $* ; do<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; # get the version<br>&nbsp; &nbsp; &nbsp; &nbsp; version=`echo $tag|cut -d- -f 2`<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; # make a tarball<br>&nbsp; &nbsp; &nbsp; &nbsp; echo "=== creating<nobr> <wbr></nobr>/tmp/perl/source/perl-$version.tar.gz"<br>&nbsp; &nbsp; &nbsp; &nbsp; git archive --format=tar --prefix=$tag/ $tag^{tree} \<br>&nbsp; &nbsp; &nbsp; &nbsp; | gzip &gt;<nobr> <wbr></nobr>/tmp/perl/source/$tag.tar.gz<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; perl cpan/Devel-PPPort/devel/buildperl.pl --config default --perl $version --test<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; # check it was installed correctly<br>&nbsp; &nbsp; &nbsp; &nbsp; if [ -d<nobr> <wbr></nobr>/tmp/perl/install/default/$tag/ ] ; then<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result="ok"<br>&nbsp; &nbsp; &nbsp; &nbsp; else<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result="not ok"<br>&nbsp; &nbsp; &nbsp; &nbsp; fi<br>&nbsp; &nbsp; &nbsp; &nbsp; echo "$result - $version" &gt;&gt;<nobr> <wbr></nobr>/tmp/buildperl.log<br> <br>&nbsp; &nbsp; done</tt></p></div> </blockquote><p>Then I just fed it with the appropriate git tags, and let it run for a while:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $<nobr> <wbr></nobr>./compile_perl `git tag -l 'perl-5.8*'`</tt></p></div> </blockquote><p>So within one and a half hour, I was able to compile, test and install all the 5.8.x versions of Perl.</p><p>I already have added the changes that allow 5.6.x, 5.8.x and 5.9.x to compile again in modern environments, and just sent the patches to P5P and Marcus Holland-Moritz.</p><p>Eventually, I'll work on adding the needed patches for versions 5.004, 5.005, and send another patch batch.</p> BooK 2009-10-29T20:44:04+00:00 journal Switching perls http://use.perl.org/~BooK/journal/39786?from=rss <p> I have a few perls compiled and installed in<nobr> <wbr></nobr><tt>/opt/perl</tt>: </p><blockquote><div><p> <tt>$ ls<nobr> <wbr></nobr>/opt/perl<br>5.10.0&nbsp; 5.6.2&nbsp; 5.8.7&nbsp; 5.8.8</tt></p></div> </blockquote><p> A long time ago, I tried to set up an environment that would setup the proper PATH to always reach the perl I wanted when typing <tt>perl</tt> on the command-line. That involved a shell script, which of course couldn't change the environment of the outer shell, so it actually started another shell, resulting in the following mess: </p><blockquote><div><p> <tt>5271 pts/2&nbsp; &nbsp; Ss&nbsp; &nbsp; &nbsp;0:01 bash<br>6182 pts/2&nbsp; &nbsp; S&nbsp; &nbsp; &nbsp; 0:00&nbsp; \_<nobr> <wbr></nobr>/bin/bash<nobr> <wbr></nobr>./perlenv 5.10.0<br>6183 pts/2&nbsp; &nbsp; S&nbsp; &nbsp; &nbsp; 0:00&nbsp; &nbsp; &nbsp; \_<nobr> <wbr></nobr>/bin/bash</tt></p></div> </blockquote><p> I could also have moved a canonical symlink around, but this had the advantage that several independent shells could run different perls. </p><p> Anyway, that was unworkable until I realized I could change the current shell environment using aliases or shell functions. So, assuming my perl binaries live in<nobr> <wbr></nobr><tt>/opt/perl/$VERSION/bin</tt>, the following bash shell function does the trick: </p><blockquote><div><p> <tt>setperl ()<br>{<br>&nbsp; &nbsp; export PATH=`echo $PATH|sed -e "s:/opt/perl/[^/]*/bin:/opt/perl/$1/bin:"`<br>}</tt></p></div> </blockquote><p> And my <tt>~/.bashrc</tt> points to the perl I want to use by default. </p> BooK 2009-10-22T08:13:55+00:00 journal Mail::Box++ http://use.perl.org/~BooK/journal/39750?from=rss <p> So <a href="http://twitter.com/dlandgren/status/4707632109">sferics' disk died</a> and took everything that wasn't backed up with it. It turns out that one of the important configuration items that weren't backed up were the configurations and subcribers lists of the Mailman mailing-lists. </p><p> To get the subscribers lists back, we didn't have many options: </p><ul> <li>Resubscribe all posters, which would also subscribe the ones who did unsubscribe at some point, and kick out all the lurkers... <i>Not so good.</i> </li><li>Process all the administrative messages to get a chronological list of subscribe/unsubscribe action, and rebuild the list from there.</li><li>Seed the list with the list of posters, if possible the subscribed ones (i.e. not the one whose mails were passed through moderation)</li></ul><p> We use Mailman for managing our mailing-lists. It works well enough for us, but it has its share of hate: </p><ul> <li>Localized admin messages are nice, but a <tt>X-Mailman-Action</tt> header would be nicer, so we would have to process the body of each actions, in all languages we might have used</li></ul><p> Luckily, it also has a few helpful headers: </p><ul> <li> <tt>List-Id</tt>, so we can process a folder full of admin messages and know about which list each message is about</li><li> <tt>X-Mailman-Approved-At</tt>, so we can detect messages sent by non-subscribed posters</li></ul><p> I used <a href="http://search.cpan.org/dist/Mail-Box/">Mail::Box</a> to create two scripts to process the messages (in French and English, so anyone who subscribed in German is out of luck) and provide some useful info (the people with the archives and the admin-fu did the actual work of fixing the lists). </p><p> Sure, <tt>Mail::Box</tt> is slow, and the interface is a bit complicated, but on the other hand it is well documented, and it's correct. </p><p> Summary at the end of the day^Wlong week-end: </p><ul> <li>(incomplete backups)--</li><li>Mailman-- # misses useful headers that would have made the job easier</li><li> <tt>Mail::Box</tt>++ # gets the job done in 20 lines</li></ul> BooK 2009-10-14T07:00:40+00:00 journal OSDC.fr http://use.perl.org/~BooK/journal/39717?from=rss <p> I just came back from <a href="http://act.osdc.fr/osdc2009fr/">OSDC.fr</a> (Open Source Developers Conference, France). This was the first edition of the conference, organized jointly by <a href="http://www.mongueurs.net/">Les Mongueurs de Perl</a>, <a href="http://www.afpy.org/">AFPy</a> (Association Francophone Python) and <a href="http://www.rubyfrance.org/">Ruby France</a>. </p><p> There were a lot more people on the Saturday than on the Friday, probably because many people were at work and it was hard for them to get work to let them go on company time. Or something. </p><p> In my view, as an attendee and an organizer <small>(I had a tiny tiny role in the organizing team)</small>, it was a great success. I saw presentations about: </p><ul> <li>OpenSUSE on the Gdium</li><li>Cucumber (Ruby)</li><li>Hadoop</li><li>Seaside (Smalltalk)</li><li>Moose (Perl)</li><li>JavaScript</li><li>MySQL</li><li>Acmeism (Ingy d&#246;t Net's new religion)</li><li>Dancer (yet another Perl web framework)</li><li>Why one shouldn't say that "reinventing the wheel" is bad, but "reinventing the toothbrush" clearly is</li><li>And a few others...</li></ul><p> The Seaside presentation was really an eye-opener showing how clean web development can be (and how exciting Smalltalk is), even though I'll probably never use it. </p><p> I keep hearing about Moose and Catalyst, but am too lazy and busy to really start investing and learning about those. So going to the Moose talk at least kept me informed. </p><p> I realized Acmeism is the religion of OSDC.fr.<nobr> <wbr></nobr><tt>;-)</tt> </p><p> <a href="http://dancer.sukria.net/">Dancer</a> is a new lightweight web framework (ported from Ruby's <a href="http://www.sinatrarb.com/">Sinatra</a>) and I really want to try it now. Maybe some of the websites' idea I have will finally see the light! </p><p> In the hallway track, I spent some time talking about gender issues with a woman (not a developer, but having been involved in a few projects with geeks) that was passing by and stopped to talk with us. I also spent a lot of time showing the power of Git to other Perl Mongers. In the end, I took over an empty slot to tour the Git object database and reply questions from the audience... I really should work on the Git tutorial I have in mind. (By the way, O'Reilly Media's <i> <a href="http://oreilly.com/catalog/9780596520137">Version Control with Git</a> </i> contains everything I would like to find in a Git tutorial, and more.) </p><p> All in all, excellent conference; I got to meet the people from over the fences and you won't believe how much they look like us.<nobr> <wbr></nobr><tt>;-)</tt> </p> BooK 2009-10-05T23:21:12+00:00 journal Test::Database, for CPAN testers http://use.perl.org/~BooK/journal/39692?from=rss <p> Hopefully, a week after my <a href="/~BooK/journal/39660">Test::Database, for CPAN Authors</a>, some CPAN authors have started to use <a href="http://search.cpan.org/dist/Test-Database/">Test::Database</a>.<nobr> <wbr></nobr>;-) </p><p> <a href="http://search.cpan.org/dist/Test-Database/">Test::Database</a> is fine to test database independence on your local setup, but to really leverage the power of CPAN Testers to fully test your module over all types of setups, it needs to be installed <i>and configured</i> on a sufficient number of tester hosts. </p><p> During my <a href="http://www.yapceurope.org/2009/">YAPC Europe 2009</a> <a href="http://yapceurope2009.org/ye2009/talk/1913">talk about Test::Database</a>, I invited several CPAN testers to attend. This is a chicken and egg type situation: this is a useful module, but CPAN authors will use it if they know it will be available on a reasinable number of testing hosts. On the other hand, few CPAN tester will bother configuring it if noone's using it anyway. </p><p> This post is basically a replay of my YAPC::Europe talk: last week I invited CPAN authors to try out <a href="http://search.cpan.org/dist/Test-Database/">Test::Database</a>, and this week I invite CPAN testers to install <i>and configure</i> <a href="http://search.cpan.org/dist/Test-Database/">Test::Database</a> as part of the toolchain installed on their smokeboxes. </p><p> And the documentation contains a <a href="http://search.cpan.org/dist/Test-Database/lib/Test/Database/Tutorial.pod">nice tutorial</a>, so it shouldn't be too hard. </p> BooK 2009-09-29T12:04:29+00:00 journal Test::Database, for CPAN authors http://use.perl.org/~BooK/journal/39660?from=rss <p> About a year ago, I realized there was no good way to test code that claims to be database independent. Even testing code that needs <i>a</i> database is difficult: most modules either use SQLite (but they don't test the database independence) or request some environment variables defining the DSN to be setup (but these are unlikely to exist on a CPAN tester's machine, though). </p><p> So I decided to write <a href="http://search.cpan.org/dist/Test-Database/">Test::Database</a>. </p><p> It took me a while to get right, but thanks to the isolation and focus that the <a href="http://qa-hackathon.org/">Birmingham QA Hackathon</a> from March 2009 gave me (and the completely broken state I put the module into at that time), I managed to come up with a satisfying version 1.00 in July this year (the module is now at version 1.06). </p><p> Basically, what <tt>Test::Database</tt> does is simply this: <i>it gives you the information you need to connect to a database that matches your testing needs</i> (implicitely allowing you to do whatever you want in there, including creating and dropping tables). </p><p> <tt>Test::Database</tt> has a single interface for test authors: </p><blockquote><div><p> <tt>&nbsp; &nbsp; my @handles = Test::Database-&gt;handles( @requests );</tt></p></div> </blockquote><p> <tt>@request</tt> is a list of "requests" for databases handles. Requests must declare the DBD they expect, and can optionaly add version-based limitations (only available for drivers supported by <tt>Test::Database</tt>). </p><p> <tt>Test::Database</tt> will return as many matching <tt>Test::Database::Handle</tt> objects as it can find or create, depending on the locally installed modules and the configuration of the user running the code. </p><p> You can then simply use the information from the <tt>Test::Database::Handle</tt> object: </p><blockquote><div><p> <tt>&nbsp; &nbsp; # $handle is a Test::Database::Handle object<br> <br>&nbsp; &nbsp; # get all the info you need and DIY<br>&nbsp; &nbsp; my ( $dsn, $user, $pass ) = $handle-&gt;connection_info();<br>&nbsp; &nbsp; my $dbh = DBI-&gt;connect( $dsn, $user, $pass );<br> <br>&nbsp; &nbsp; # be lazy and let it do the DBI-&gt;connect( $dsn, $user, $pass ) for you<br>&nbsp; &nbsp; my $dbh = $handle-&gt;dbh();</tt></p></div> </blockquote><p> So once you've added support for MySQL to your module (in addition to SQLite), you can simply edit the test script like so: </p><blockquote><div><p> <tt>&nbsp; &nbsp; my @handles = Test::Database-&gt;handles( 'SQLite', 'mysql' );</tt></p></div> </blockquote><p> And your test suite will pick up a MySQL handle wherever there's one available. </p><p> <small> Many thanks to <a href="http://search.cpan.org/~sukria/">SUKRIA</a>, who'll be the first CPAN author to really use Test::Database to test a CPAN module (namely, <a href="http://search.cpan.org/dist/Coat-Persistent/">Coat::Persistent</a>, when the latest release finally hits CPAN). </small> </p> BooK 2009-09-22T01:40:22+00:00 journal My favorite Perl logo http://use.perl.org/~BooK/journal/39620?from=rss <p>TIMTOPL - <i>There is more than one Perl logo</i> <small>(BAOTATM - <i>But All Of Them Are Trade Marked</i>)</small>:</p><ul> <li> <a href="http://images.google.fr/images?q=perl+camel">The Camel</a>: <a href="http://www.cpan.org/src/unsupported/4.036/">Perl 4</a> and <a href="http://dev.perl.org/perl5/">Perl 5</a> ("<a href="http://oreilly.com/pub/a/oreilly/perl/usage/">The Perl camel image is a trademark of</a> <a href="http://www.oreilly.com/">O'Reilly Media, Inc.</a> <a href="http://oreilly.com/pub/a/oreilly/perl/usage/faq.html">Used with permission.</a>") </li><li> <a href="http://images.google.fr/images?q=perl+onion">The Onion</a>: <a href="http://www.perlfoundation.org/">The Perl Foundation</a> ("<a href="http://www.perlfoundation.org/perl_trademark">The Perl logo is a trademark of the Perl Foundation.</a>") </li><li> <a href="http://images.google.fr/images?q=perl+camelia">Camelia The Butterfly</a>: <a href="http://perl6.org/">Perl 6</a> ("<a href="http://svn.pugscode.org/pugs/misc/camelia.txt">The Camelia image is a trademark of Larry Wall</a>") </li></ul><p> My favorite Perl logo, by far, is the onion. When it appeared, I found it the perfect logo: simple, recognizable, easy to include and modify. It was quickly adopted by the community (I remember seeing T-shirts with the logo very early on). </p><p> In his <a href="http://www.wall.org/~larry/onion/onion.html">2nd state of the Onion</a>, Larry said: </p><blockquote><div><p> <i> If you cut an onion, it looks like <a href="http://www.wall.org/~larry/onion/talk.html#s-33">this</a>. If we take this to be a picture of the world of Perl, then I must be that little bit of onion inside. Around me are some of the early adopters of Perl, who are now revered as heroes of the revolution. As more people have joined the movement, new layers have been added. </i></p></div> </blockquote><p> When I saw the onion logo, this image sprung to my mind. Maybe the Onion is the symbol of the Perl Community, rather than of Perl itself. </p> BooK 2009-09-13T22:53:39+00:00 journal A reason to like the Perl 6 logo http://use.perl.org/~BooK/journal/39609?from=rss <p> It seems that some people <a href="http://www.reddit.com/r/programming/comments/9f7yt/new_main_perl_6_website_perl6org/c0cjjil">don't</a> <a href="/~sigzero/journal/39552">like</a> the new <a href="http://perl6.org/">Perl 6</a> logo (<a href="http://svn.pugscode.org/pugs/misc/camelia.txt">Camelia</a>) </p><p> Do you remember the time when the worst thing people said about Perl was "it's vaporware"? The people working on Perl 6 had a hard time failing to convince them of the contrary, no matter how many commits happened, how many tests were passing, how many implementations were in the works. </p><p> Today, it seems the worst thing people can say about Perl 6 matches<nobr> <wbr></nobr><tt>/the logo is (gay|feminine|childish)/</tt>. To me, this looks like the easiest kind of critique to discard. </p><p> As for those who think that the camel is more manly than a colorful butterly, maybe they should remember that <a href="http://www.perlmonks.org/?node_id=31583">the Camel is named Amelia</a>. </p><p> And by the way, it seems to have made people forget the "vaporware" argument. Even if you don't like how the new logo looks, you can still love it for that. </p><p> <small> This was supposed to be my first post for the Ironman Perl blogging contest. I resolved to post every Monday... Late before even starting!<nobr> <wbr></nobr>:-( </small> </p> BooK 2009-09-10T13:26:22+00:00 journal White Camel http://use.perl.org/~BooK/journal/39429?from=rss <p>This year at OSCON, I received a <a href="http://www.perl.org/advocacy/white_camel/">White Camel</a> award. Since I didn't attend OSCON, my good friends Liz and Wendy arranged a little ceremony at the end of YAPC::Europe 2009 where David Adler gave me a big box containing a "Schr&#246;dinger White Camel". </p><p> Even though I knew about the award and was warned about the ceremony, my little thank-you talk didn't come out so well: I was too moved to make sense. </p><p> Here's what I wanted to say: </p><blockquote><div><p> <i> I'm deeply honoured and extremely proud of receiving this award. </i> </p><p> <i> First I would like to thank the people who decided I was worthy of it. </i> </p><p> <i> And I would like to add that I'm actually driven by example: in this room I see plenty of people who organize Perl workshops and conferences all over the world, that run mongers groups and technical meetings... All these people are setting the example I followed in my work with the French Perl Mongers and the YAPC Europe Foundation. </i> </p><p> <i> So, thank you very much to all of you, for setting such a good example to follow. </i> </p></div> </blockquote><p>Thanks to everyone involved, and thanks a lot to the Perl community for being what it is: a large group of friendly people achieving wonderful things, both technical and non-technical.</p> BooK 2009-08-09T14:35:45+00:00 journal /me &#9829; git http://use.perl.org/~BooK/journal/38216?from=rss <p>I just uploaded <a href="http://search.cpan.org/dist/Git-FastExport/">Git::FastExport</a> 0.07 on CPAN. I think I've reached a stable point in the stitching algorithm, where I'm confident that the results of stitching any number of git repositories together will be consistent. I'll probably do a presentation about it at the next Amsterdam.pm and Lyon.pm technical meetings.</p><p>To celebrate, I also setup a web server with my <a href="http://git.bruhat.net/">public git repositories</a>. Clone away! Over time, I'll move most of my older CVS/Subversion repositories to git. </p><p>By the way, I love git because:</p><ul> <li>git add -i (lets one pick up hunks to add or not, and even edit them!)</li><li>it gives me full control over the history</li><li>it makes it very easy to share code</li><li>it makes it very easy to contribute code</li><li>it makes me code faster</li></ul> BooK 2009-01-04T14:04:45+00:00 journal An iCalendar for all Perl events http://use.perl.org/~BooK/journal/38206?from=rss <p>Wondering when the next Perl event is? Wouldn't it be nice if the information was automatically available in your calendar?</p><p>Cry no more, for I have setup an iCalendar file holding all the Perl events (conferences, workshops, hackathons) for which I have enough date information. Simply <a href="http://www.yapceurope.org/ical/conferences.ics">subscribe to all Perl events worldwide</a> using your favorite calendar tool. This calendar is hosted by the <a href="http://www.yapceurope.org/">YAPC Europe Foundation</a>. </p><p>If some data is missing or incomplete, please let me know, preferably by sending me a patch against <a href="http://www.yapceurope.org/events/conferences.yml">the source YAML file</a> (this is the best way to ensure fast updates).</p> BooK 2009-01-02T17:05:52+00:00 journal Onward to the 100th Perl conference! http://use.perl.org/~BooK/journal/36259?from=rss <p> In order to produce <a href="http://act.mongueurs.net/act-conferences.png">this graph</a>, I ended up gathering all the information I could find about Perl grassroots conferences (so this list doesn't contain any of the TPC/OSCON conferences, but on the other hand, it does contain several unconfirmed or canceled Perl conferences). </p><p> The <a href="http://www.yapceurope.org/events/conferences.yml">raw YAML data</a> will be hosted and maintained by the <a href="http://www.yapceurope.org/">YAPC Europe Foundation</a>, but you can email me directly with additions and updates. </p><p> Here are some statistics I computed from the list:</p><ul> <li>Total number of confirmed Perl conferences since German Perl Workshop (1999-02-17): 99 </li></ul><p>Conference types: </p><ul> <li>workshop: 52 </li><li>yapc: 35 </li><li>osdc: 7 </li><li>hackathon: 5 </li></ul><p> Conferences per year (of which using <a href="http://act.mongueurs.net/">Act</a>): </p><ul> <li>1999: 2</li><li>2000: 3</li><li>2001: 3</li><li>2002: 4</li><li>2003: 6 (1)</li><li>2004: 12 (1)</li><li>2005: 14 (6)</li><li>2006: 15 (4)</li><li>2007: 19 (9)</li><li>2008: 21 (14)</li></ul><p> Breakdown per continent/country: </p><ul> <li>Europe: 60 <ul> <li>Germany: 11 </li><li>United Kingdom: 7 </li><li>Netherlands: 7 </li><li>France: 6 </li><li>Austria: 5 </li><li>Italy: 4 </li><li>Denmark: 4 </li><li>Hungary: 3 </li><li>Russia: 3 </li><li>Sweden: 2 </li><li>Norway: 2 </li><li>Portugal: 2 </li><li>Belarus: 1 </li><li>Belgium: 1 </li><li>Croatia: 1 </li><li>Ukraine: 1 </li></ul></li><li>America: 23 <ul> <li>United States: 13 </li><li>Brazil: 6 </li><li>Canada: 4 </li></ul></li><li>Asia: 12 <ul> <li>Israel: 5 </li><li>Taiwan: 3 </li><li>Japan: 3 </li></ul></li><li>Oceania: 5 <ul> <li>Australia: 5 </li></ul></li></ul><p> Breakdown per continent/conference: </p><ul> <li>Europe: 60 <ul> <li>German Perl Workshop: 10 </li><li>YAPC Europe: 9 </li><li>Dutch Perl Workshop: 5 </li><li>Nordic Perl Workshop: 5 </li><li>French Perl Workshop: 5 </li><li>Italian Perl Workshop: 4 </li><li>Austrian Perl Workshop: 4 </li><li>London Perl Workshop: 4 </li><li>Hungarian Perl Workshop: 3 </li><li>Ukrainian Perl Workshop: 1 </li><li>Scandinavian Perl Workshop: 1 </li><li>Russian Perl Workshop: 1 </li><li>Croatian Perl Workshop: 1 </li><li>Oslo QA Hackathon: 1 </li><li>Portuguese Perl Workshop: 1 </li><li>YAPC Russia: 1 </li><li>Belgian Perl Workshop: 1 </li><li>Far East Perl Workshop: 1 </li><li>European Perl Hackathon: 1 </li><li>Belarusian Perl Workshop: 1 </li></ul></li><li>America: 23 <ul> <li>YAPC North America: 10 </li><li>YAPC Brazil: 3 </li><li>YAPC South America: 3 </li><li>Pittsburgh Perl Workshop: 2 </li><li>Chicago Hackathon: 2 </li><li>YAPC Canada: 1 </li><li>Toronto Hackathon: 1 </li><li>Frozen Perl: 1 </li></ul></li><li>Asia: 12 <ul> <li>YAPC Israel: 3 </li><li>YAPC Asia: 3 </li><li>OSDC.tw: 2 </li><li>Perl Workshop in Israel: 1 </li><li>YAPC Taipei: 1 </li><li>OSDC Israel: 1 </li></ul></li><li>Oceania: 5 <ul> <li>OSDC.au: 4 </li><li>YAPC Australia: 1 </li></ul></li></ul><p> Cancelled conferences:</p><ul> <li> <a href="http://www.neperlworkshop.org/">New England Perl Workshop</a> (2007)</li><li> <a href="http://www.osdc.org.il/2007/">OSDC Israel</a> (2007)</li><li> <a href="http://act.perl.org.il/ilpw2007/hackathon.html">Israeli Pub crawl/Hackathon</a> (2007)</li></ul><p> <b>Update:</b> included the Toronto hackathon in the statistics.</p><p> <b>Update:</b> the Israeli pubcrawl/hackathon was cancelled.</p> BooK 2008-04-28T14:25:02+00:00 journal Graphing module usage http://use.perl.org/~BooK/journal/34717?from=rss <p> This is a really quick hack. I wanted to see which modules used which in my debugging session. This is exactly what <a href="http://search.cpan.org/dist/Devel-TraceUse/">Devel::TraceUse</a> does. </p><p> I wanted to be able to see those relationship and be able to doodle on a piece of paper and stuff. So, here goes, thanks to <a href="http://search.cpan.org/dist/GraphViz/">GraphViz</a>:</p><blockquote><div><p> <tt>#!/usr/bin/env perl<br>use strict;<br>use warnings;<br>use GraphViz;<br> <br>my $png = shift || 'use.png';<br>my $g = GraphViz-&gt;new( rankdir =&gt; 1 );<br> <br>my @stack;<br>while (&lt;&gt;) {<br>&nbsp; &nbsp; # first node<br>&nbsp; &nbsp;<nobr> <wbr></nobr>/^Modules used from (.*):/ &amp;&amp; do {<br>&nbsp; &nbsp; &nbsp; &nbsp; $g-&gt;add_node($1);<br>&nbsp; &nbsp; &nbsp; &nbsp; @stack = ($1);<br>&nbsp; &nbsp; };<br>&nbsp; &nbsp; # all other nodes<br>&nbsp; &nbsp;<nobr> <wbr></nobr>/^((?:&nbsp; )+)(\S+),/ &amp;&amp; do {<br>&nbsp; &nbsp; &nbsp; &nbsp; my $idx = length($1) / 2;<br>&nbsp; &nbsp; &nbsp; &nbsp; $stack[$idx] = $2;<br>&nbsp; &nbsp; &nbsp; &nbsp; $g-&gt;add_node($2);<br>&nbsp; &nbsp; &nbsp; &nbsp; $g-&gt;add_edge( $stack[ $idx - 1 ] =&gt; $2 );<br>&nbsp; &nbsp; };<br> <br>&nbsp; &nbsp; # ignore all other lines<br>}<br> <br>$g-&gt;as_png($png);</tt></p></div> </blockquote> BooK 2007-10-19T10:20:38+00:00 journal Alice Claire Rose Bruhat-Souche http://use.perl.org/~BooK/journal/33509?from=rss <p>On Tuesday, June 12, 2007 at 23:50, Alice Claire Rose Bruhat-Souche was born.<br> She weighs 3.2 kg and measures 49 cm(*). </p><p> The mother and baby were just fine when I left them this morning.<nobr> <wbr></nobr>:-) </p><p> I'm too busy spreading the word and reading the incoming emails to actually realize. I'll go back there soon anyway, I already miss both of them too much. </p><p> <small> (*) I think that's about half a stone (or seven pounds?) and one foot seven inches. Hey guys, why don't you use the metric system, like most of the advanced civilisations? </small> </p> BooK 2007-06-13T08:47:29+00:00 journal Net::Proxy 0.08 http://use.perl.org/~BooK/journal/33083?from=rss <p>I forgot to update the Changes file in the distribution, so here goes:</p><blockquote><div><p> <tt>0.08 Mon Apr 23 19:08:30 CEST 2007<br>&nbsp; &nbsp; &nbsp; &nbsp; [ENHANCEMENTS]<br>&nbsp; &nbsp; &nbsp; &nbsp; - the hook callback now receives the socket on which the data<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; was received, in addition to the connector<br>&nbsp; &nbsp; &nbsp; &nbsp; [NEW CONNECTOR]<br>&nbsp; &nbsp; &nbsp; &nbsp; - Net::Proxy::Connector::connect_ssl<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; (combines Net::Proxy::Connector::connect and<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Net::Proxy::Connector::ssl in a single connector)<br>&nbsp; &nbsp; &nbsp; &nbsp; [TESTS]<br>&nbsp; &nbsp; &nbsp; &nbsp; - made tests more robust when connector prerequisites are missing<br>&nbsp; &nbsp; &nbsp; &nbsp; - test Net::Proxy::Connector::ssl as an "in" connector<br>&nbsp; &nbsp; &nbsp; &nbsp; - test the start_cleartext option of Net::Proxy::Connector::ssl</tt></p></div> </blockquote><p>Basically, the <tt>connect_ssl</tt> connector lets one send anything through a web proxy (just like the <tt>connect</tt> connector), and properly encapsulate it in an SSL connection. Which means you'll need a decapsulating SSL proxy at the other, but <tt> <a href="http://search.cpan.org/dist/Net-Proxy/">Net::Proxy</a> </tt> can do that for you too.<nobr> <wbr></nobr><tt>:-)</tt> </p> BooK 2007-04-23T21:23:58+00:00 journal Hackathon war story http://use.perl.org/~BooK/journal/32555?from=rss <p>So, there I am, on Friday night, sitting next to Luis, trying to install Act on my laptop. Starting from scratch, by compiling my Perl, my mod_perl and Apache. </p><blockquote><div><p> <tt>$ cd ~/src/perl-5.8.8<br>$ sh Configure -Dprefix=~/local -des<br>...<br>$ make &amp;&amp; make test &amp;&amp; make install<br>$ ls ~/local/</tt></p></div> </blockquote><p> <b>Nothing?</b> Mmm... </p><blockquote><div><p> <tt>$ cd ~/src/perl-5.8.8<br>$ ls \~<br>bin&nbsp; lib&nbsp; man</tt></p></div> </blockquote><p> Oh. Stupid me, Configure didn't expand the ~ like I thought it would. Well, let's get rid of this. </p><blockquote><div><p> <tt>$ rm -rf ~</tt></p></div> </blockquote><p> "Are you sure you want to do this?" asks Luis... <b>OH CRAP.</b> </p><p> So every participant of the hackathon is making fun of me, now. Well, you can't always choose the reason why people will remember you.<nobr> <wbr></nobr><tt>;-)</tt> </p> BooK 2007-03-03T20:22:59+00:00 journal Five things you didn't know about me http://use.perl.org/~BooK/journal/32177?from=rss <p>Ack! I've been <a href="http://use.perl.org/~domm/journal/32175">hit</a> as well by the game of the month... So, I therefore present to you:</p><p> <b>Five things you did not know about me</b> (or Georges Perec)</p><ol> <li>I created the first web page ever about French author Georges Perec, back in 1993 or 1994.</li><li>I met the girl who became my wife on the Internet in April 1995, thanks to my web page about Georges Perec. We created <a href="http://www.oulipo.net/Colophon/">the first web site</a> about <a href="http://www.oulipo.net/">Oulipo</a> and the <a href="http://quatramaran.ens.fr/mailman/listinfo/oulipo/">oulipo mailing-list</a> together in October 1995, about 6 months before meeting each other in real life.</li><li>I used to write poetry under constraints (in the Oulipo fashion, a group of which Georges Perec was a prominent member), but the only poems I wrote for her were written before we were together. They had her name <i>concealed</i> inside them because I was afraid to come out to her and lose my closest friend (some of those poems were published in <a href="http://www.oulipotes.net/BLO/BLO6/">a book a group of friends crafted for her on the occasion of her 30th birthday</a>).</li><li>At our wedding, I namely thanked Georges Perec in my speech, for being the cause of our encounter (although he was dead for more than 10 years when she wrote that first message in my guestbook).</li><li>We're going to have our first child in June. If it's a boy we're <b>not</b> going to name him Georges (nor Zowie).</li></ol><p>And now I'd like to tag David Landgren (<a href="/~grinder/journal/">grinder</a>), &#201;ric Cholet (<a href="http://www.logilune.com/eric/">echo</a>), Rafael Garcia-Suarez (<a href="/~rafael/journal/">rgs</a>), Elizabeth Mattijsen (<a href="http://perlmonks.org/?node_id=272239">Liz</a>), and <a href="/~Abigail/journal/">Abigail</a>. (more Euro-Perl hackers) </p><p> <small>Wow, it's been years since I haven't talked so much about Georges Perec...</small> </p> BooK 2007-01-17T10:15:20+00:00 journal All tests successful (6 subtests UNEXPECTEDLY SUCCEEDED) http://use.perl.org/~BooK/journal/32153?from=rss <p>In July 2004, I discovered a bug in my module <a href="http://search.cpan.org/dist/Pod-POM-View-HTML-Filter/">Pod::POM::View::HTML::Filter</a>: when processing a POM object through the View, elements of the POM object were deleted. And it only happened when processing a section with the filter based on Perl::Tidy... So I wrote some some tests to exercise the bug, marked the failing ones as TODO tests, and moved on, thinking it was an issue with Perl::Tidy.</p><p>Within the last few days, I spent some time cleaning up PPVHF, reorganising the test suite, working around the same old problem with Pod::POM, committing like crazy and enhancing the module itself.</p><p>One of these enhancements made me rewrite a small bunch of lines at the core of the module logic. It was a hell of a surprise when the test script told me <tt>6/46 unexpectedly succeeded</tt>!</p><p>So the bug was probably mine, after all... I've removed the TODO marker from the tests, but they'll stay here, as I still don't understand what was wrong in that code, and I don't want the bug to creep back in.</p><p>Version 0.06 should hit a mirror near you within the next few hours.</p> BooK 2007-01-16T00:54:35+00:00 journal New job in March http://use.perl.org/~BooK/journal/31966?from=rss <p> I resigned from $job yesterday. I was very secretive about actually looking for a job, so it came as a surprise to my peers and boss. I spent a good time there, both in Paris and Lyon, and learnt a lot, both from my peers and my clients; but after nine years in the same company (and four mergers), it was time to move on and try something completely different. </p><p> As from March 19, 2007, I'll be working with the fine folks at booking.com as a developer (improving QA will also be part of my job). I'll still be working from Lyon (with another Lyon.pm monger, David Morel) and will travel to Amsterdam twice a month.</p> BooK 2006-12-19T09:16:09+00:00 journal Quoting myself on 5.10 http://use.perl.org/~BooK/journal/31740?from=rss <p> During the French Perl Workshop, David Landgren (the current p5p summarizer) made a long presentation about what's new in Perl 5.10. My reaction to it:</p><blockquote><div><p> <i> Perl 5 is the only programming language that inherits from the future! </i></p></div> </blockquote> BooK 2006-11-28T13:23:45+00:00 journal Acme::MetaSyntactic::summerwine http://use.perl.org/~BooK/journal/31532?from=rss <p>Yesterday I pushed <a href="http://search.cpan.org/dist/Acme-MetaSyntactic/">Acme-MetaSyntactic</a> 0.99 on CPAN. Among its 99 themes, this distribution includes a theme proposed by Smylers. He bought the right to decide what the last theme before 1.00 would be at the last YAPC::Europe auction. Please check out his <tt>Acme::MetaSyntactic::summerwine</tt> theme, it's a nice conclusion to a long series of funny weeks.</p><p>He also unknowingly bought the dubious privilege to define what is going to be the last Acme::MetaSyntactic update in while: I had lots of plans for 1.00 (reduce the size of the distribution, distribute maintainership, etc.), but haven't found the time to organise the repository and distribution creation. So, contrary to <a href="http://use.perl.org/~BooK/journal/22732">what I thought 22 months ago</a>, Acme::MetaSyntactic 1.00 will probably not be published next week.</p> BooK 2006-11-07T10:39:39+00:00 journal