1Perl::Critic(3) User Contributed Perl Documentation Perl::Critic(3)
2
3
4
6 Perl::Critic - Critique Perl source code for best-practices.
7
9 use Perl::Critic;
10 my $file = shift;
11 my $critic = Perl::Critic->new();
12 my @violations = $critic->critique($file);
13 print @violations;
14
16 Perl::Critic is an extensible framework for creating and applying
17 coding standards to Perl source code. Essentially, it is a static
18 source code analysis engine. Perl::Critic is distributed with a number
19 of Perl::Critic::Policy modules that attempt to enforce various coding
20 guidelines. Most Policy modules are based on Damian Conway's book Perl
21 Best Practices. However, Perl::Critic is not limited to PBP and will
22 even support Policies that contradict Conway. You can enable, disable,
23 and customize those Polices through the Perl::Critic interface. You
24 can also create new Policy modules that suit your own tastes.
25
26 For a command-line interface to Perl::Critic, see the documentation for
27 perlcritic. If you want to integrate Perl::Critic with your build
28 process, Test::Perl::Critic provides an interface that is suitable for
29 test programs. Also, Test::Perl::Critic::Progressive is useful for
30 gradually applying coding standards to legacy code. For the ultimate
31 convenience (at the expense of some flexibility) see the criticism
32 pragma.
33
34 If you'd like to try Perl::Critic without installing anything, there is
35 a web-service available at <http://perlcritic.com>. The web-service
36 does not yet support all the configuration features that are available
37 in the native Perl::Critic API, but it should give you a good idea of
38 what it does.
39
40 Also, ActivePerl includes a very slick graphical interface to Perl-
41 Critic called "perlcritic-gui". You can get a free community edition
42 of ActivePerl from <http://www.activestate.com>.
43
45 Perl::Critic runs on Perl back to Perl 5.6.1. It relies on the PPI
46 module to do the heavy work of parsing Perl.
47
49 The "Perl::Critic" module is considered to be a public class. Any
50 changes to its interface will go through a deprecation cycle.
51
53 "new( [ -profile => $FILE, -severity => $N, -theme => $string, -include
54 => \@PATTERNS, -exclude => \@PATTERNS, -top => $N, -only => $B,
55 -profile-strictness => $PROFILE_STRICTNESS_{WARN|FATAL|QUIET}, -force
56 => $B, -verbose => $N ], -color => $B, -pager => $string, -allow-unsafe
57 => $B, -criticism-fatal => $B)"
58 "new()"
59 Returns a reference to a new Perl::Critic object. Most arguments
60 are just passed directly into Perl::Critic::Config, but I have
61 described them here as well. The default value for all arguments
62 can be defined in your .perlcriticrc file. See the "CONFIGURATION"
63 section for more information about that. All arguments are
64 optional key-value pairs as follows:
65
66 -profile is a path to a configuration file. If $FILE is not
67 defined, Perl::Critic::Config attempts to find a .perlcriticrc
68 configuration file in the current directory, and then in your home
69 directory. Alternatively, you can set the "PERLCRITIC" environment
70 variable to point to a file in another location. If a
71 configuration file can't be found, or if $FILE is an empty string,
72 then all Policies will be loaded with their default configuration.
73 See "CONFIGURATION" for more information.
74
75 -severity is the minimum severity level. Only Policy modules that
76 have a severity greater than $N will be applied. Severity values
77 are integers ranging from 1 (least severe violations) to 5 (most
78 severe violations). The default is 5. For a given "-profile",
79 decreasing the "-severity" will usually reveal more Policy
80 violations. You can set the default value for this option in your
81 .perlcriticrc file. Users can redefine the severity level for any
82 Policy in their .perlcriticrc file. See "CONFIGURATION" for more
83 information.
84
85 If it is difficult for you to remember whether severity "5" is the
86 most or least restrictive level, then you can use one of these
87 named values:
88
89 SEVERITY NAME ...is equivalent to... SEVERITY NUMBER
90 --------------------------------------------------------
91 -severity => 'gentle' -severity => 5
92 -severity => 'stern' -severity => 4
93 -severity => 'harsh' -severity => 3
94 -severity => 'cruel' -severity => 2
95 -severity => 'brutal' -severity => 1
96
97 The names reflect how severely the code is criticized: a "gentle"
98 criticism reports only the most severe violations, and so on down
99 to a "brutal" criticism which reports even the most minor
100 violations.
101
102 -theme is special expression that determines which Policies to
103 apply based on their respective themes. For example, the following
104 would load only Policies that have a 'bugs' AND 'pbp' theme:
105
106 my $critic = Perl::Critic->new( -theme => 'bugs && pbp' );
107
108 Unless the "-severity" option is explicitly given, setting "-theme"
109 silently causes the "-severity" to be set to 1. You can set the
110 default value for this option in your .perlcriticrc file. See the
111 "POLICY THEMES" section for more information about themes.
112
113 -include is a reference to a list of string @PATTERNS. Policy
114 modules that match at least one "m/$PATTERN/ixms" will always be
115 loaded, irrespective of all other settings. For example:
116
117 my $critic = Perl::Critic->new(-include => ['layout'], -severity => 4);
118
119 This would cause Perl::Critic to apply all the "CodeLayout::*"
120 Policy modules even though they have a severity level that is less
121 than 4. You can set the default value for this option in your
122 .perlcriticrc file. You can also use "-include" in conjunction
123 with the "-exclude" option. Note that "-exclude" takes precedence
124 over "-include" when a Policy matches both patterns.
125
126 -exclude is a reference to a list of string @PATTERNS. Policy
127 modules that match at least one "m/$PATTERN/ixms" will not be
128 loaded, irrespective of all other settings. For example:
129
130 my $critic = Perl::Critic->new(-exclude => ['strict'], -severity => 1);
131
132 This would cause Perl::Critic to not apply the "RequireUseStrict"
133 and "ProhibitNoStrict" Policy modules even though they have a
134 severity level that is greater than 1. You can set the default
135 value for this option in your .perlcriticrc file. You can also use
136 "-exclude" in conjunction with the "-include" option. Note that
137 "-exclude" takes precedence over "-include" when a Policy matches
138 both patterns.
139
140 -single-policy is a string "PATTERN". Only one policy that matches
141 "m/$PATTERN/ixms" will be used. Policies that do not match will be
142 excluded. This option has precedence over the "-severity",
143 "-theme", "-include", "-exclude", and "-only" options. You can set
144 the default value for this option in your .perlcriticrc file.
145
146 -top is the maximum number of Violations to return when ranked by
147 their severity levels. This must be a positive integer.
148 Violations are still returned in the order that they occur within
149 the file. Unless the "-severity" option is explicitly given,
150 setting "-top" silently causes the "-severity" to be set to 1. You
151 can set the default value for this option in your .perlcriticrc
152 file.
153
154 -only is a boolean value. If set to a true value, Perl::Critic
155 will only choose from Policies that are mentioned in the user's
156 profile. If set to a false value (which is the default), then
157 Perl::Critic chooses from all the Policies that it finds at your
158 site. You can set the default value for this option in your
159 .perlcriticrc file.
160
161 -profile-strictness is an enumerated value, one of
162 "$PROFILE_STRICTNESS_WARN" in Perl::Critic::Utils::Constants (the
163 default), "$PROFILE_STRICTNESS_FATAL" in
164 Perl::Critic::Utils::Constants, and "$PROFILE_STRICTNESS_QUIET" in
165 Perl::Critic::Utils::Constants. If set to
166 "$PROFILE_STRICTNESS_FATAL" in Perl::Critic::Utils::Constants,
167 Perl::Critic will make certain warnings about problems found in a
168 .perlcriticrc or file specified via the -profile option fatal. For
169 example, Perl::Critic normally only "warn"s about profiles
170 referring to non-existent Policies, but this value makes this
171 situation fatal. Correspondingly, "$PROFILE_STRICTNESS_QUIET" in
172 Perl::Critic::Utils::Constants makes Perl::Critic shut up about
173 these things.
174
175 -force is a boolean value that controls whether Perl::Critic
176 observes the magical "## no critic" annotations in your code. If
177 set to a true value, Perl::Critic will analyze all code. If set to
178 a false value (which is the default) Perl::Critic will ignore code
179 that is tagged with these annotations. See "BENDING THE RULES" for
180 more information. You can set the default value for this option in
181 your .perlcriticrc file.
182
183 -verbose can be a positive integer (from 1 to 11), or a literal
184 format specification. See Perl::Critic::Violation for an
185 explanation of format specifications. You can set the default
186 value for this option in your .perlcriticrc file.
187
188 -unsafe directs Perl::Critic to allow the use of Policies that are
189 marked as "unsafe" by the author. Such policies may compile
190 untrusted code or do other nefarious things.
191
192 -color and -pager are not used by Perl::Critic but is provided for
193 the benefit of perlcritic.
194
195 -criticism-fatal is not used by Perl::Critic but is provided for
196 the benefit of criticism.
197
198 -color-severity-highest, -color-severity-high, -color-severity-
199 medium, -color-severity-low, and -color-severity-lowest are not
200 used by Perl::Critic, but are provided for the benefit of
201 perlcritic. Each is set to the Term::ANSIColor color specification
202 to be used to display violations of the corresponding severity.
203
204 -files-with-violations and -files-without-violations are not used
205 by Perl::Critic, but are provided for the benefit of perlcritic, to
206 cause only the relevant filenames to be displayed.
207
209 "critique( $source_code )"
210 Runs the $source_code through the Perl::Critic engine using all the
211 Policies that have been loaded into this engine. If $source_code
212 is a scalar reference, then it is treated as a string of actual
213 Perl code. If $source_code is a reference to an instance of
214 PPI::Document, then that instance is used directly. Otherwise, it
215 is treated as a path to a local file containing Perl code. This
216 method returns a list of Perl::Critic::Violation objects for each
217 violation of the loaded Policies. The list is sorted in the order
218 that the Violations appear in the code. If there are no
219 violations, this method returns an empty list.
220
221 "add_policy( -policy => $policy_name, -params => \%param_hash )"
222 Creates a Policy object and loads it into this Critic. If the
223 object cannot be instantiated, it will throw a fatal exception.
224 Otherwise, it returns a reference to this Critic.
225
226 -policy is the name of a Perl::Critic::Policy subclass module. The
227 'Perl::Critic::Policy' portion of the name can be omitted for
228 brevity. This argument is required.
229
230 -params is an optional reference to a hash of Policy parameters.
231 The contents of this hash reference will be passed into to the
232 constructor of the Policy module. See the documentation in the
233 relevant Policy module for a description of the arguments it
234 supports.
235
236 " policies() "
237 Returns a list containing references to all the Policy objects that
238 have been loaded into this engine. Objects will be in the order
239 that they were loaded.
240
241 " config() "
242 Returns the Perl::Critic::Config object that was created for or
243 given to this Critic.
244
245 " statistics() "
246 Returns the Perl::Critic::Statistics object that was created for
247 this Critic. The Statistics object accumulates data for all files
248 that are analyzed by this Critic.
249
251 For those folks who prefer to have a functional interface, The
252 "critique" method can be exported on request and called as a static
253 function. If the first argument is a hashref, its contents are used to
254 construct a new Perl::Critic object internally. The keys of that hash
255 should be the same as those supported by the "Perl::Critic::new()"
256 method. Here are some examples:
257
258 use Perl::Critic qw(critique);
259
260 # Use default parameters...
261 @violations = critique( $some_file );
262
263 # Use custom parameters...
264 @violations = critique( {-severity => 2}, $some_file );
265
266 # As a one-liner
267 %> perl -MPerl::Critic=critique -e 'print critique(shift)' some_file.pm
268
269 None of the other object-methods are currently supported as static
270 functions. Sorry.
271
273 Most of the settings for Perl::Critic and each of the Policy modules
274 can be controlled by a configuration file. The default configuration
275 file is called .perlcriticrc. Perl::Critic will look for this file in
276 the current directory first, and then in your home directory.
277 Alternatively, you can set the "PERLCRITIC" environment variable to
278 explicitly point to a different file in another location. If none of
279 these files exist, and the "-profile" option is not given to the
280 constructor, then all the modules that are found in the
281 Perl::Critic::Policy namespace will be loaded with their default
282 configuration.
283
284 The format of the configuration file is a series of INI-style blocks
285 that contain key-value pairs separated by '='. Comments should start
286 with '#' and can be placed on a separate line or after the name-value
287 pairs if you desire.
288
289 Default settings for Perl::Critic itself can be set before the first
290 named block. For example, putting any or all of these at the top of
291 your configuration file will set the default value for the
292 corresponding constructor argument.
293
294 severity = 3 #Integer or named level
295 only = 1 #Zero or One
296 force = 0 #Zero or One
297 verbose = 4 #Integer or format spec
298 top = 50 #A positive integer
299 theme = (pbp || security) && bugs #A theme expression
300 include = NamingConventions ClassHierarchies #Space-delimited list
301 exclude = Variables Modules::RequirePackage #Space-delimited list
302 criticism-fatal = 1 #Zero or One
303 color = 1 #Zero or One
304 allow-unsafe = 1 #Zero or One
305 pager = less #pager to pipe output to
306
307 The remainder of the configuration file is a series of blocks like
308 this:
309
310 [Perl::Critic::Policy::Category::PolicyName]
311 severity = 1
312 set_themes = foo bar
313 add_themes = baz
314 maximum_violations_per_document = 57
315 arg1 = value1
316 arg2 = value2
317
318 "Perl::Critic::Policy::Category::PolicyName" is the full name of a
319 module that implements the policy. The Policy modules distributed with
320 Perl::Critic have been grouped into categories according to the table
321 of contents in Damian Conway's book Perl Best Practices. For brevity,
322 you can omit the 'Perl::Critic::Policy' part of the module name.
323
324 "severity" is the level of importance you wish to assign to the Policy.
325 All Policy modules are defined with a default severity value ranging
326 from 1 (least severe) to 5 (most severe). However, you may disagree
327 with the default severity and choose to give it a higher or lower
328 severity, based on your own coding philosophy. You can set the
329 "severity" to an integer from 1 to 5, or use one of the equivalent
330 names:
331
332 SEVERITY NAME ...is equivalent to... SEVERITY NUMBER
333 ----------------------------------------------------
334 gentle 5
335 stern 4
336 harsh 3
337 cruel 2
338 brutal 1
339
340 The names reflect how severely the code is criticized: a "gentle"
341 criticism reports only the most severe violations, and so on down to a
342 "brutal" criticism which reports even the most minor violations.
343
344 "set_themes" sets the theme for the Policy and overrides its default
345 theme. The argument is a string of one or more whitespace-delimited
346 alphanumeric words. Themes are case-insensitive. See "POLICY THEMES"
347 for more information.
348
349 "add_themes" appends to the default themes for this Policy. The
350 argument is a string of one or more whitespace-delimited words. Themes
351 are case- insensitive. See "POLICY THEMES" for more information.
352
353 "maximum_violations_per_document" limits the number of Violations the
354 Policy will return for a given document. Some Policies have a default
355 limit; see the documentation for the individual Policies to see whether
356 there is one. To force a Policy to not have a limit, specify
357 "no_limit" or the empty string for the value of this parameter.
358
359 The remaining key-value pairs are configuration parameters that will be
360 passed into the constructor for that Policy. The constructors for most
361 Policy objects do not support arguments, and those that do should have
362 reasonable defaults. See the documentation on the appropriate Policy
363 module for more details.
364
365 Instead of redefining the severity for a given Policy, you can
366 completely disable a Policy by prepending a '-' to the name of the
367 module in your configuration file. In this manner, the Policy will
368 never be loaded, regardless of the "-severity" given to the
369 Perl::Critic constructor.
370
371 A simple configuration might look like this:
372
373 #--------------------------------------------------------------
374 # I think these are really important, so always load them
375
376 [TestingAndDebugging::RequireUseStrict]
377 severity = 5
378
379 [TestingAndDebugging::RequireUseWarnings]
380 severity = 5
381
382 #--------------------------------------------------------------
383 # I think these are less important, so only load when asked
384
385 [Variables::ProhibitPackageVars]
386 severity = 2
387
388 [ControlStructures::ProhibitPostfixControls]
389 allow = if unless # My custom configuration
390 severity = cruel # Same as "severity = 2"
391
392 #--------------------------------------------------------------
393 # Give these policies a custom theme. I can activate just
394 # these policies by saying `perlcritic -theme larry`
395
396 [Modules::RequireFilenameMatchesPackage]
397 add_themes = larry
398
399 [TestingAndDebugging::RequireTestLables]
400 add_themes = larry curly moe
401
402 #--------------------------------------------------------------
403 # I do not agree with these at all, so never load them
404
405 [-NamingConventions::Capitalization]
406 [-ValuesAndExpressions::ProhibitMagicNumbers]
407
408 #--------------------------------------------------------------
409 # For all other Policies, I accept the default severity,
410 # so no additional configuration is required for them.
411
412 For additional configuration examples, see the perlcriticrc file that
413 is included in this examples directory of this distribution.
414
415 Damian Conway's own Perl::Critic configuration is also included in this
416 distribution as examples/perlcriticrc-conway.
417
419 A large number of Policy modules are distributed with Perl::Critic.
420 They are described briefly in the companion document
421 Perl::Critic::PolicySummary and in more detail in the individual
422 modules themselves. Say "perlcritic -doc PATTERN" to see the perldoc
423 for all Policy modules that match the regex "m/PATTERN/ixms"
424
425 There are a number of distributions of additional policies on CPAN. If
426 Perl::Critic doesn't contain a policy that you want, some one may have
427 already written it. See the "SEE ALSO" section below for a list of
428 some of these distributions.
429
431 Each Policy is defined with one or more "themes". Themes can be used
432 to create arbitrary groups of Policies. They are intended to provide
433 an alternative mechanism for selecting your preferred set of Policies.
434 For example, you may wish disable a certain subset of Policies when
435 analyzing test programs. Conversely, you may wish to enable only a
436 specific subset of Policies when analyzing modules.
437
438 The Policies that ship with Perl::Critic have been broken into the
439 following themes. This is just our attempt to provide some basic
440 logical groupings. You are free to invent new themes that suit your
441 needs.
442
443 THEME DESCRIPTION
444 --------------------------------------------------------------------------
445 core All policies that ship with Perl::Critic
446 pbp Policies that come directly from "Perl Best Practices"
447 bugs Policies that that prevent or reveal bugs
448 certrec Policies that CERT recommends
449 certrule Policies that CERT considers rules
450 maintenance Policies that affect the long-term health of the code
451 cosmetic Policies that only have a superficial effect
452 complexity Policies that specifically relate to code complexity
453 security Policies that relate to security issues
454 tests Policies that are specific to test programs
455
456 Any Policy may fit into multiple themes. Say "perlcritic -list" to get
457 a listing of all available Policies and the themes that are associated
458 with each one. You can also change the theme for any Policy in your
459 .perlcriticrc file. See the "CONFIGURATION" section for more
460 information about that.
461
462 Using the "-theme" option, you can create an arbitrarily complex rule
463 that determines which Policies will be loaded. Precedence is the same
464 as regular Perl code, and you can use parentheses to enforce precedence
465 as well. Supported operators are:
466
467 Operator Alternative Example
468 -----------------------------------------------------------------
469 && and 'pbp && core'
470 || or 'pbp || (bugs && security)'
471 ! not 'pbp && ! (portability || complexity)'
472
473 Theme names are case-insensitive. If the "-theme" is set to an empty
474 string, then it evaluates as true all Policies.
475
477 Perl::Critic takes a hard-line approach to your code: either you comply
478 or you don't. In the real world, it is not always practical (nor even
479 possible) to fully comply with coding standards. In such cases, it is
480 wise to show that you are knowingly violating the standards and that
481 you have a Damn Good Reason (DGR) for doing so.
482
483 To help with those situations, you can direct Perl::Critic to ignore
484 certain lines or blocks of code by using annotations:
485
486 require 'LegacyLibaray1.pl'; ## no critic
487 require 'LegacyLibrary2.pl'; ## no critic
488
489 for my $element (@list) {
490
491 ## no critic
492
493 $foo = ""; #Violates 'ProhibitEmptyQuotes'
494 $barf = bar() if $foo; #Violates 'ProhibitPostfixControls'
495 #Some more evil code...
496
497 ## use critic
498
499 #Some good code...
500 do_something($_);
501 }
502
503 The "## no critic" annotations direct Perl::Critic to ignore the
504 remaining lines of code until a "## use critic" annotation is found. If
505 the "## no critic" annotation is on the same line as a code statement,
506 then only that line of code is overlooked. To direct perlcritic to
507 ignore the "## no critic" annotations, use the "--force" option.
508
509 A bare "## no critic" annotation disables all the active Policies. If
510 you wish to disable only specific Policies, add a list of Policy names
511 as arguments, just as you would for the "no strict" or "no warnings"
512 pragmas. For example, this would disable the "ProhibitEmptyQuotes" and
513 "ProhibitPostfixControls" policies until the end of the block or until
514 the next "## use critic" annotation (whichever comes first):
515
516 ## no critic (EmptyQuotes, PostfixControls)
517
518 # Now exempt from ValuesAndExpressions::ProhibitEmptyQuotes
519 $foo = "";
520
521 # Now exempt ControlStructures::ProhibitPostfixControls
522 $barf = bar() if $foo;
523
524 # Still subjected to ValuesAndExpression::RequireNumberSeparators
525 $long_int = 10000000000;
526
527 Since the Policy names are matched against the "## no critic" arguments
528 as regular expressions, you can abbreviate the Policy names or disable
529 an entire family of Policies in one shot like this:
530
531 ## no critic (NamingConventions)
532
533 # Now exempt from NamingConventions::Capitalization
534 my $camelHumpVar = 'foo';
535
536 # Now exempt from NamingConventions::Capitalization
537 sub camelHumpSub {}
538
539 The argument list must be enclosed in parentheses or brackets and must
540 contain one or more comma-separated barewords (e.g. don't use quotes).
541 The "## no critic" annotations can be nested, and Policies named by an
542 inner annotation will be disabled along with those already disabled an
543 outer annotation.
544
545 Some Policies like "Subroutines::ProhibitExcessComplexity" apply to an
546 entire block of code. In those cases, the "## no critic" annotation
547 must appear on the line where the violation is reported. For example:
548
549 sub complicated_function { ## no critic (ProhibitExcessComplexity)
550 # Your code here...
551 }
552
553 Policies such as "Documentation::RequirePodSections" apply to the
554 entire document, in which case violations are reported at line 1.
555
556 Use this feature wisely. "## no critic" annotations should be used in
557 the smallest possible scope, or only on individual lines of code. And
558 you should always be as specific as possible about which Policies you
559 want to disable (i.e. never use a bare "## no critic"). If
560 Perl::Critic complains about your code, try and find a compliant
561 solution before resorting to this feature.
562
564 Coding standards are deeply personal and highly subjective. The goal
565 of Perl::Critic is to help you write code that conforms with a set of
566 best practices. Our primary goal is not to dictate what those
567 practices are, but rather, to implement the practices discovered by
568 others. Ultimately, you make the rules -- Perl::Critic is merely a
569 tool for encouraging consistency. If there is a policy that you think
570 is important or that we have overlooked, we would be very grateful for
571 contributions, or you can simply load your own private set of policies
572 into Perl::Critic.
573
575 The modular design of Perl::Critic is intended to facilitate the
576 addition of new Policies. You'll need to have some understanding of
577 PPI, but most Policy modules are pretty straightforward and only
578 require about 20 lines of code. Please see the Perl::Critic::DEVELOPER
579 file included in this distribution for a step-by-step demonstration of
580 how to create new Policy modules.
581
582 If you develop any new Policy modules, feel free to send them to
583 "<team@perlcritic.com>" and I'll be happy to consider putting them into
584 the Perl::Critic distribution. Or if you would like to work on the
585 Perl::Critic project directly, you can fork our repository at
586 <https://github.com/Perl-Critic/Perl-Critic.git>.
587
588 The Perl::Critic team is also available for hire. If your organization
589 has its own coding standards, we can create custom Policies to enforce
590 your local guidelines. Or if your code base is prone to a particular
591 defect pattern, we can design Policies that will help you catch those
592 costly defects before they go into production. To discuss your needs
593 with the Perl::Critic team, just contact "<team@perlcritic.com>".
594
596 Perl::Critic requires the following modules:
597
598 B::Keywords
599
600 Config::Tiny
601
602 Exception::Class
603
604 File::Spec
605
606 File::Spec::Unix
607
608 File::Which
609
610 IO::String
611
612 List::MoreUtils
613
614 List::Util
615
616 Module::Pluggable
617
618 Perl::Tidy
619
620 Pod::Spell
621
622 PPI
623
624 Pod::PlainText
625
626 Pod::Select
627
628 Pod::Usage
629
630 Readonly
631
632 Scalar::Util
633
634 String::Format
635
636 Task::Weaken
637
638 Term::ANSIColor
639
640 Text::ParseWords
641
642 version
643
645 You are encouraged to subscribe to the public mailing list at
646 <https://groups.google.com/d/forum/perl-critic>. At least one member
647 of the development team is usually hanging around in
648 <irc://irc.perl.org/#perlcritic> and you can follow Perl::Critic on
649 Twitter, at <https://twitter.com/perlcritic>.
650
652 There are a number of distributions of additional Policies available. A
653 few are listed here:
654
655 Perl::Critic::More
656
657 Perl::Critic::Bangs
658
659 Perl::Critic::Lax
660
661 Perl::Critic::StricterSubs
662
663 Perl::Critic::Swift
664
665 Perl::Critic::Tics
666
667 These distributions enable you to use Perl::Critic in your unit tests:
668
669 Test::Perl::Critic
670
671 Test::Perl::Critic::Progressive
672
673 There is also a distribution that will install all the Perl::Critic
674 related modules known to the development team:
675
676 Task::Perl::Critic
677
679 Scrutinizing Perl code is hard for humans, let alone machines. If you
680 find any bugs, particularly false-positives or false-negatives from a
681 Perl::Critic::Policy, please submit them at
682 <https://github.com/Perl-Critic/Perl-Critic/issues>. Thanks.
683
685 Adam Kennedy - For creating PPI, the heart and soul of Perl::Critic.
686
687 Damian Conway - For writing Perl Best Practices, finally :)
688
689 Chris Dolan - For contributing the best features and Policy modules.
690
691 Andy Lester - Wise sage and master of all-things-testing.
692
693 Elliot Shank - The self-proclaimed quality freak.
694
695 Giuseppe Maxia - For all the great ideas and positive encouragement.
696
697 and Sharon, my wife - For putting up with my all-night code sessions.
698
699 Thanks also to the Perl Foundation for providing a grant to support
700 Chris Dolan's project to implement twenty PBP policies.
701 <http://www.perlfoundation.org/april_1_2007_new_grant_awards>
702
703 Thanks also to this incomplete laundry list of folks who have
704 contributed to Perl::Critic in some way: Daniel Mita, Gregory Oschwald,
705 Mike O'Regan, Tom Hukins, Omer Gazit, Evan Zacks, Paul Howarth, Sawyer
706 X, Christian Walde, Dave Rolsky, Jakub Wilk, Roy Ivy III, Oliver
707 Trosien, Glenn Fowler, Matt Creenan, Alex Balhatchet, Sebastian Paaske
708 Torholm, Stuart A Johnston, Dan Book, Steven Humphrey, James Raspass,
709 Nick Tonkin, Harrison Katz, Douglas Sims, Mark Fowler, Alan Berndt,
710 Neil Bowers, Sergey Romanov, Gabor Szabo, Graham Knop, Mike Eldridge,
711 David Steinbrunner, Kirk Kimmel, Guillaume Aubert, Dave Cross, Anirvan
712 Chatterjee, Todd Rinaldo, Graham Ollis, Karen Etheridge, Jonas Bromso,
713 Olaf Alders, Jim Keenan, Slaven ReziX, Szymon NieznaXski.
714
716 Jeffrey Ryan Thalhammer <jeff@imaginative-software.com>
717
719 Copyright (c) 2005-2019 Imaginative Software Systems. All rights
720 reserved.
721
722 This program is free software; you can redistribute it and/or modify it
723 under the same terms as Perl itself. The full text of this license can
724 be found in the LICENSE file included with this module.
725
726
727
728perl v5.34.0 2021-07-22 Perl::Critic(3)