I need pack examples for the Camel

I'm working on the pack section in Programming Perl and learning about all the templates things that I've never used.

Does anyone have examples (or know where some are) that use:

  • @ with a repeat count
  • . with a repeat count
  • ( with a repeat count

Also, which modules make extensive use of pack? I used to in my Mac::iTunes (now outdated) module, but I was going very rudimentary things that I now see I could have done much better with other pack features.

Google Code Search for "pack(" turns up a lot of everyone's favorite CGI parameter undo-er, many Perl/Tk things, and lots of simple templates for pack. I want to see the really knarly and mind bending ones. Send me a good one that we put in the book, and I'll send you the book for free.

DBD::SQLite 1.35 release planned for 22nd of November

It's been a fairly quiet year for DBD::SQLite, but largely in a positive sense.

The release rate and delta of SQLite itself has been fairly tame, and in Perl land we've seen a significant reduction in the severity of bugs compared to 2010.

Because of the significance of DBD::SQLite and the need for extended testing periods, it has been my policy to allow smaller fixes to accumulate without doing a release and to release DBD::SQLite in line with SQLite releases that recommend upgrading.

The recent 3.7.8 release of SQLite does not come with an upgrade recommendation for our current SQLite version, but does suggest upgrading as optional. This release contains some significant index performance improvements (described as "orders of magnitude faster") for large CREATE INDEX commands, and DISTINCT, ORDER BY and GROUP BY
statements are now faster in all cases.

The 3.7.8 release also contains some changes to make SQLite play nicer with Windows anti-virus programs.

Validation::Class - Completely Rewritten

I have completely rewritten Validation-Class using Moose. The new Validation::Class is better documented and well-tested. I created Validation-Class for a variety of reasons including but not limited to the fact that I wanted/needed a data validation library that was as reusable as possible, syntactically easy to define, and didn't care much about context.

This spawned a new way of looking at data validation, using a class as an application's firewall representing the rules of the data allowed to pass through it, not bound to a use-case and flexible.

I encourage you to check it out and please leave feedback:

Validation-Class has been shipped, Moosified since 2.0.0:
Github: https://github.com/alnewkirk/Validation-Class-Moose
CPAN: https://metacpan.org/module/Validation::Class

perlanalyst approaching ...

Last week I went to my first Perl workshop: 13. Deutscher Perl-Workshop. It has been a great experience – great talks and even greater people.

On the train to and from Frankfurt and at the workshop itself I hacked a bit on my pet project: the Perl Analyst. The goal is to build a PPI-based tool that parses your Perl documents, it may then answer your questions about your sources. The tool and the modules it consists of may also lead to refactoring tools.

There is a running prototype on github which may reach CPAN soon. Currently you may use it to search for declaration of subroutines and lexical variables as well as the use of strings. You may search for them by exact matches or regular expressions.

Extracting your archives

I'm on a bit of a roll about unpacking archives. Last week I wrote about peeking into archives and recently I was wondering about extracting archives.

The classic tool for extracting archives is Archive::Extract. This module was originally written for CPANPLUS and has been in the Perl core since 5.10.0. It tries a variety of methods for extracting archives, from pure-Perl modules such as Archive::Zip and Archive::Tar (portable but slow) to external tar and unzip commands (unportable but slightly faster).

Having played around with libarchive, a "C library and command-line tools for reading and writing tar, cpio, zip, ISO, and other archive formats", I wondered if it would be interesting to use it instead.

Behold my newly-written module Archive::Extract::Libarchive. This uses libarchive to extract archives, extracts most archive formats and is quite fast. It requires libarchive to be installed.

How fast? Well, it depends on what you are extracting. If you happen to be extracting all the current CPAN distributions (for a total of 7.1G), then Archive::Extract (with PREFER_BIN) takes about 20 minutes while Archive::Extract::Libarchive takes about two minutes.

Yet another tool for your archive extracting toolbox...

Introducing PrePAN - Social Reviewing Site for Perl Modules

I'll introduce PrePAN to you here. PrePAN is a website for all Perl Mongers, especially for those who have intention to upload their Perl modules to CPAN. PrePAN aims to be a good place for them to make discussion about Perl modules pre-uploaded to CPAN (`PrePAN' is named after that).

I introduced the website at YAPC::Asia 2011. Some Perl mongers have submitted their modules already. Please give a look at them at PrePAN.

What's you can at PrePAN?

  • You can submit your Perl modules and call for review.
  • ...if it's just a proposal/idea before implementation.
  • Make discussion about them by comments.
  • If you want to invite co-developers, PrePAN may be a help of you.

Motivation

Solution to Your Problem

You may wirte a useful module for your job or your own purpose. You may think it might be worthy for others. However, you may worry about something like below:

One More Record? from YAPC::Asia Tokyo 2011

YAPC::Asia Tokyo 2011 was record breaking, but I think we just broke one more record: namely, number of blog posts

We collected at least over 150 blog posts (~157) from our attendees about YAPC::Asia Tokyo 2011. We had 672 attendees total, so that means about 23% of our attendees wrote something in their blog. I'm pretty sure this will pay off in the future, as it will be much much easier for us to tell our would-be sponsors and attendees what YAPC is like

BTW, this year punytan created a simple form for people to submit the url, and a lot of people including myself just kept collecting them blog entries. punitan++.

If you're an organizer, make sure to tell your attendees that their YAPC ain't over until you blog about it!

Marpa::XS is now beta

I am very happy to announce that Marpa::XS is now beta. Marpa::XS will kept stable. Changes to its interface will be especially avoided.

What is Marpa?

Marpa is an advance over recursive descent and yacc. I hope the Marpa algorithm will become the standard parser for problems too big for regular expressions.

About blogs.perl.org

blogs.perl.org is a common blogging platform for the Perl community. Written in Perl and offering the modern features you’ve come to expect in blog platforms, the site is run by Dave Cross and Aaron Crane, with a design donated by Six Apart, Ltd.