[Fwd: [PATCH] Pod::Find should ignore SCM files and dirs]
authorAlan Burlison <Alan.Burlison@uk.sun.com>
Fri, 28 May 2004 23:28:44 +0000 (00:28 +0100)
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Tue, 1 Jun 2004 12:24:30 +0000 (12:24 +0000)
Message-ID: <40B7BD1C.40309@sun.com>

p4raw-id: //depot/perl@22886

lib/Pod/Find.pm

index 21af123..bfd6f40 100644 (file)
@@ -13,7 +13,7 @@
 package Pod::Find;
 
 use vars qw($VERSION);
-$VERSION = 0.24;   ## Current version of this package
+$VERSION = 0.24_01;   ## Current version of this package
 require  5.005;   ## requires this Perl version or later
 use Carp;
 
@@ -201,7 +201,11 @@ sub pod_find
         File::Find::find( sub {
             my $item = $File::Find::name;
             if(-d) {
-                if($dirs_visited{$item}) {
+                if($item =~ m{/(?:RCS|CVS|SCCS|\.svn)$}) {
+                    $File::Find::prune = 1;
+                    return;
+                }
+                elsif($dirs_visited{$item}) {
                     warn "Directory '$item' already seen, skipping.\n"
                         if($opts{-verbose});
                     $File::Find::prune = 1;