in reply to Re: perlcritic and OO Perl (including Moose) idioms (perlcritic is dead/dumb, perlcriticrc for moose)
in thread perlcritic and OO Perl (including Moose) idioms

If I were in a position to establish the rules I would not bother with perlcritic but instead rely much more heavily on code reviews. But ...

Unfortunately, much of this will be a team decision, and I already know that the team is going to want to use perlcritic simply because it will automate some things (yeah, right.) In the meantime, I am looking for tips such as what documentation I really need to look at, and how others have addressed what I think are common problems.

Thanks for the response, it was helpful.

Update: changed title back to what I had originally.

  • Comment on Re^2: perlcritic and OO Perl (including Moose) idioms

Replies are listed 'Best First'.
Re^3: perlcritic and OO Perl (including Moose) idioms
by kcott (Archbishop) on Sep 20, 2013 at 06:10 UTC
    "Unfortunately, much of this will be a team decision, and I already know that the team is going to want to use perlcritic simply because it will automate some things (yeah, right.) In the meantime, I am looking for tips such as what documentation I really need to look at, and how others have addressed what I think are common problems."

    I'd suggest that you get your team to read the first section of the Preface to "Perl Best Practices" and note how many times the words "guidelines" and "suggestions" are used. Ensure they've read the the first sentence of the third paragraph: "This book doesn't doesn't try to offer the one true universal and unequivocal set of best practices.". Show them the publishing date (2005) and make certain they understand this is eight years old.

    All too often I've come across statements like "We've got to code it that way because PBP says so." Your team really do need to understand that these are guidelines and suggestions, not rules and regulations. I think once you get that message across, you'll have a much easier time of getting a concensus on a configuration which is useful in that it identifies code which could be improved, as opposed to one that blindly follows every PBP dot-point.

    Just so you know, I like a fair bit of the advice in PBP: parts I follow, other parts I don't. I didn't want this to come across as a PBP bashing exercise on my part. :-)

    -- Ken

Re^3: perlcritic and OO Perl (including Moose) idioms (perlcritic is dead/dumb, perlcriticrc for moose)
by Anonymous Monk on Sep 20, 2013 at 03:26 UTC
    ah, to work on teams ; to work at all :)
Re^3: perlcritic and OO Perl (including Moose) idioms
by Anonymous Monk on Oct 05, 2018 at 22:27 UTC

    Turns out there is now such a thing

    Perl::Critic::Freenode - A set of Perl::Critic policies to enforce the practices generally recommended by the denizens of #perl on Freenode IRC. Because this policy "theme" is designed to be used with zero configuration on the command line, some duplication will occur if it is used in combination with core Perl::Critic policies.

    perlcritic --theme freenode script.pl

    2018-10-21 Athanasius changed <h1> tags to <h3>