2007-08-17 21:57:20 +01:00
|
|
|
#!/usr/bin/perl
|
|
|
|
#
|
2007-08-20 00:02:27 +01:00
|
|
|
# Written by Jason Edgecombe based on the Test::Pod documentation. The
|
|
|
|
# best way to run it is to run:
|
|
|
|
#
|
|
|
|
# prove check-pod
|
|
|
|
#
|
|
|
|
# from the doc/man-pages directory, which will show any errors found in
|
|
|
|
# any of the POD files.
|
2009-10-08 18:20:33 +01:00
|
|
|
#
|
|
|
|
# Extended by Davor Ocelic to support explicit list of POD files or
|
|
|
|
# sections to check:
|
|
|
|
#
|
|
|
|
# check-pod pod1/fs.pod
|
|
|
|
# check-pod pod5
|
|
|
|
# check-pod pod1 pod8/volserver.pod
|
|
|
|
#
|
2007-08-17 21:57:20 +01:00
|
|
|
|
|
|
|
use strict;
|
|
|
|
use Test::More;
|
|
|
|
eval "use Test::Pod 1.00";
|
|
|
|
|
|
|
|
plan skip_all => "Test::Pod 1.00 required for testing POD" if $@;
|
2011-02-04 22:23:30 +00:00
|
|
|
my @poddirs = qw( pod1 pod3 pod5 pod8 );
|
2009-10-08 18:20:33 +01:00
|
|
|
|
|
|
|
my @list;
|
|
|
|
for ( @ARGV ? @ARGV : @poddirs ) {
|
|
|
|
if ( -f ) {
|
|
|
|
push @list, $_
|
|
|
|
} elsif ( -d ) {
|
2010-07-16 01:21:26 +01:00
|
|
|
push @list, grep { !m,fragments/, } all_pod_files( $_ )
|
2009-10-08 18:20:33 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
all_pod_files_ok( @list );
|