podgrep - grep in pod sections only
podgrep [-i] [-p] [-f] [-h] pattern [ files ... ]
This program searches each paragraph in a pod document and prints each paragraph that matches the supplied pattern. This pod may be mixed with program code, such as in a module.
Options are:
means case insensitive match
means page output though the user's pager. The pager will be primed with an argument to search for the string. This highlights the result.
means format output though the pod2text program.
means check for matches in pod =head and =item headers alone, and to keep printing podagraphs until the next header is found.
=head
=item
$ podgrep mail `pmpath CGI` (prints out podagraphs from the CGI.pm manpage that mention mail) $ podgrep -i destructor `sitepods` (prints out podagraphs that mention destructors in the site-installed pods) $ podgrep -i 'type.?glob' `stdpods` (prints out podagraphs that mention typeglob in the standard pods) $ podgrep -hpfi "lock" `faqpods` (prints out all podagraphs with "lock" in the headers case-insensitively, then then formats these with pod2text, then shows them in the pager with matches high-lighted) $ podgrep -fh seek `podpath perlfunc` (prints out and formats podagraphs from the standard perlfunc manpage whose headers or items contain "seek".)
faqpods(1), pfcat(1), pmpath(1), pod2text(1), podpath(1), sitepods(1), stdpods(1), and tcgrep(1).
For a pager, the author likes these environment settings (in the login startup, of course):
$ENV{PAGER} = "less"; $ENV{LESS} = "MQeicsnf";
Copyright (c) 1999 Tom Christiansen
This is free software. You may modify it and distribute it under Perl's Artistic Licence. Modified versions must be clearly indicated.
To install Devel::Loaded, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Devel::Loaded
CPAN shell
perl -MCPAN -e shell install Devel::Loaded
For more information on module installation, please visit the detailed CPAN module installation guide.