NAME

P4::C4::Ignore - Read a cvs ignore file

SYNOPSIS

use P4::C4::Ignore;

my $ign = new P4::C4::Ignore();
$ign->isIgnored ($filename);

...

DESCRIPTION

The P4::C4::Ignore package reads .cvsignore files and provides matching functions.

IGNORE FILES

Ignore files are mostly compatible with CVS. The list of ignores is initialized with:

tags    TAGS
.make.state     .nse_depinfo
*~      #*      .#*     ,*      _$*     *$
*.old   *.bak   *.BAK   *.orig  *.rej   .del-*
*.a     *.olb   *.o     *.obj   *.so    *.exe
*.Z     *.elc   *.ln
core

The patterns found in `.cvsignore' are only valid for the directory that contains them, not for any sub-directories. A single exclamation mark (`!') clears the ignore list.

The wildcards * and ? are honored, no other wildcards are currently supported.

METHODS

$ign = P4::C4::Ignore->new ( opts )

Create a new Ignore hash. "filename=>filename" may be specified to override the default of .cvsignore for reading the ignore file.

Any .cvsignore files that are read are cached in this object to save time. Thus if a .cvsignore file is being written by the application, a new object will have to be created to clear the hash.

$self->is_ignored ( $file )

Returns true if the file is being ignored.

SEE ALSO

P4::C4

DISTRIBUTION

The latest version is available from CPAN. The latest version is available from CPAN and from http://www.veripool.com/.

Copyright 2002-2004 by Wilson Snyder. This package is free software; you can redistribute it and/or modify it under the terms of either the GNU Lesser General Public License or the Perl Artistic License.

AUTHORS

Wilson Snyder <wsnyder@wsnyder.org>