Home > Main > PBP 2nd ed.? Just open it up!

PBP 2nd ed.? Just open it up!

There are some long-overdue calls out there calling for the second edition of “Perl Best Practices”. And more often than not, people having good ideas don’t realize they are proposing a dreadful solution.

I do consider PBP a good collection of recommendations. But sometimes, I loathe the impact it has on the community. It’s the Perl bible, Part II (just after the Camel book) and many people just go on believing in it. What we get as a result is a free community’s dependency on a non-free book.

At my place of work, we run Perl::Critic on SVN commits with PBP rule set. Everytime it finds something, it tells me to “Look at page XX of PBP for details”. So much for online help… Yes, I do have a copy of PBP in the office, even on my table. Sadly, it’s a german translation which has slightly different page numbering.

Why does a code analyzer cite some particular book edition? Imagine a second edition of PBP coming out. What do we get then, a command line parameter for book version? For a translation thereof? How many modules will we have to update? Usually a book gets updated when code changes, not other way around.

An even more heretical question: what happens if I don’t actually own a copy of PBP? Am I doomed to stay ignorant of best practices just because I’m just starting to learn and can’t or don’t want to shell out money for a book?

Other language communities are different. Both Ruby and Python give you extensive online documentation and also some dead-tree docs if you need them. But you don’t have to buy a book just to learn some best practices, those are readily available in blogs, wikis and what not. Perl’s community seems to trust in holy cows (camels or dogs for that matter) and just keeps insisting on buying books. “Modern” is something very different, though.

I know I can read PBP on Google Books, with several dozens of invisible pages. But PBP should have been online a long time ago. It should have been a community work from the beginning, since best practices is one of the first things a newbie needs.

There is only one way for PBP for the future: O’Reilly and Damian should open it up, just like “Higher Order Perl” has done. Make it downloadable at first, make it a community-driven project later. O’Reilly could even release a dead-tree edition every now and then, but the first step would be to free Damian from all the “please update PBP” e-mails — it’s perfectly probable that he doesn’t have time to do so and even more probable, no personal interest in bringing the second edition out. In that case, maybe he should raise his voice and work with O’Reilly on making that vastly important book a community project.

  1. brunov
    May 22nd, 2009 at 22:41 | #1

    It doesn’t replace having a copy of the book, but running perlcritic with “—verbose 10” outputs a pretty decent description of the policies that were violated in the input script.

  2. May 22nd, 2009 at 22:44 | #2

    Hmm. Running “—verbose 10” is not something I usually do and besides, I’m not the one writing those scripts, but point taken ;)

  3. May 23rd, 2009 at 07:20 | #3

    http://books.google.de/books?id=yMMRnPQ7CSMC&printsec=frontcover&dq=perl+best+practices&ei=apUXStqJAoPcygTuhZXDAQ#PPP1,M1

    A few pages are missing, but I use it a lot because you can jump to pages very easy.

  4. May 23rd, 2009 at 16:38 | #4

    I’d love to see more best practices summations of development toolchain stuff, like using local lib, building your application as a CPAN module, etc. For me those things are even more important in some ways than coding practices, since coding practices and recommended modules will change more frequently over time.

  1. No trackbacks yet.