Test::CheckManifest - Check if your Manifest matches your distro
=head1 VERSION
version 1.43
=head1 SYNOPSIS
use Test::CheckManifest;
ok_manifest();
=head2 EXPORT
There is only one method exported: C<ok_manifest>
=head1 METHODS
=head2 ok_manifest [{exclude => $arref}][$msg]
checks whether the Manifest file matches the distro or not. To match a distro
the Manifest has to name all files that come along with the distribution.
To check the Manifest file, this module searches for a file named C<MANIFEST>.
To exclude some directories from this test, you can specify these dirs in the
hashref.
ok_manifest({exclude => ['/var/test/']});
is ok if the files in C</path/to/your/dist/var/test/> are not named in the
C<MANIFEST> file. That means that the paths in the exclude array must be
"pseudo-absolute" (absolute to your distribution).
To use a "filter" you can use the key "filter"
ok_manifest({filter => [qr/\.svn/]});
With that you can exclude all files with an '.svn' in the filename or in the
path from the test.
These files would be excluded (as examples):
=over 4
=item * /dist/var/.svn/test
=item * /dist/lib/test.svn
=back
You can also combine "filter" and "exclude" with 'and' or 'or' default is 'or':
ok_manifest({exclude => ['/var/test'],
filter => [qr/\.svn/],
bool => 'and'});
These files have to be named in the C<MANIFEST>:
=over 4
=item * /var/foo/.svn/any.file
=item * /dist/t/file.svn
=item * /var/test/test.txt
=back
These files not:
=over 4
=item * /var/test/.svn/*
=item * /var/test/file.svn
=back
By default, C<ok_manifest> will look for the file C<MANIFEST> in the current working directory (which is how tests are traditionally run). If you wish to specify a different directory, you may pass the C<file> or C<dir> parameters, for example:
ok_manifest({dir => '/path/to/my/dist/'});
=head1 EXCLUDING FILES
Beside C<filter> and C<exclude> there is another way to exclude files:
C<MANIFEST.SKIP>. This is a file with filenames that should be excluded:
t/my_very_own.t
file_to.skip
=head1 REPLACE THIS MODULE
You can replace the test scripts using C<Test::CheckManifest> with this one