in reply to detecting pod in files?
my $file = '/tmp/file'; open(IN, "<$file") or die "$0: cannot read file '$file': $!"; my $pod = 0; while (<IN>) { $pod = 1, last if /^=\w/ } #/^=(pod|head\d|over|item|back|cut)/ might be more accurate #=begin, =end, and =for are ommited because they would #usualy be ignored by pod2* close(IN); pod2html($file) if $pod;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: detecting pod in files?
by brian_d_foy (Abbot) on Aug 17, 2005 at 17:17 UTC |