On Sun, 01 Feb 2015 18:07:18 -0500 Harry Putnam <rea...@newsguy.com> wrote:
> Shawn H Corey <shawnhco...@gmail.com> writes: > > > On Sun, 01 Feb 2015 11:12:46 -0500 > > Harry Putnam <rea...@newsguy.com> wrote: > > > >> Shawn H Corey <shawnhco...@gmail.com> writes: > >> > >> > http://metacpan.org/pod/Perl::Critic > >> > >> Feeding my sorry script to the advertised webpage like by using the > >> posted method of testing Perl::Critic with no installation. > > > > I have installed Perl::Critic on my machine. To use it, I just run > > perlcritic: > > > > perlcritic file > > Does it have to be fed a *.pm type file or will any perlscript work. > > Does the script have to run beyond compilatiom phase, to get helpful > output? > > It works with any file, even those that aren't Perl scripts (expect a lot of errors). As Paul Johnson says, try it with the -c option first but note: -c causes Perl to check the syntax of the program and then exit without executing it. Actually, it will execute and "BEGIN", "UNITCHECK", or "CHECK" blocks and any "use" statements: these are considered as occurring outside the execution of your program. "INIT" and "END" blocks, however, will be skipped. All of perl's command-line options can be found in `perldoc perlrun` http://perldoc.perl.org/perlrun.html#Command-Switches -- Don't stop where the ink does. Shawn -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/