ExtUti...nifest(3perl)
πΈ NAME πΈ
ExtUtils::Manifest β utilities to write and check a MANIFEST file π
(yes bestie, this is the ExtUti...nifest(3perl) page β section 3perl of the perl manpages, the title just got cut off on the way in, it's giving mysterious iykyk energy π
)
β¨ VERSION β¨
version 1.75 π
π¦ SYNOPSIS π¦
use ExtUtils::Manifest qw(...funcs to import...);
mkmanifest();
my @missing_files = manicheck;
my @skipped = skipcheck;
my @extra_files = filecheck;
my($missing, $extra) = fullcheck;
my $found = manifind();
my $manifest = maniread();
manicopy($read,$target);
maniadd({$file => $comment, ...});
π« DESCRIPTION π«
...
fr fr, that's the whole description, it's literally three dots and honestly? iconic. π
π FUNCTIONS π
ExtUtils::Manifest exports no functions by default. The following ones are exported on request β you gotta ask nicely π₯Ί:
π mkmanifest
mkmanifest();
Writes all the files in and below the current directory into your MANIFEST. It works basically like the result of running this Unix command:
find . > MANIFEST
Every file that matches any regular expression sitting in a file called MANIFEST.SKIP (if that file even exists) gets ignored, no cap π«.
Heads up bestie: anyMANIFESTfile you already have gets saved asMANIFEST.bakfirst. πΎ
π§ manifind
my $found = manifind();
returns a hash reference. The keys of that hash are the files found below the current directory. Slay. π
π manicheck
my @missing_files = manicheck();
checks if all the files inside a MANIFEST in the current directory actually exist. If MANIFEST and the tree below the current directory are in sync, it silently returns an empty list β not a peep, silent like a library π€«. Otherwise it returns a list of the files that are listed in the MANIFEST but are missing from the directory, and by default it also prints those names to STDERR.
π filecheck
my @extra_files = filecheck();
finds files below the current directory that are not mentioned in the MANIFEST file. If there's an optional MANIFEST.SKIP file, it will be consulted. Any file matching a regular expression in that file will not be reported as missing from the MANIFEST file. The list of any extraneous files found gets returned, and by default it's also reported to STDERR.
π fullcheck
my($missing, $extra) = fullcheck();
does a manicheck() and a filecheck(), and returns them as two array refs. Two-for-one deal, we love a bundle π
π«Ά skipcheck
my @skipped = skipcheck();
lists all the files that get skipped because of your MANIFEST.SKIP file. Periodt.
β maniread
my $manifest = maniread();
my $manifest = maniread($manifest_file);
reads a MANIFEST file with the name you give it (it defaults to MANIFEST in the current directory) and hands you back a HASH reference where the files are the keys and the comments are the values. Blank lines, plus any line that starts with "#" inside the MANIFEST file, get discarded ποΈ.
π maniskip
my $skipchk = maniskip();
my $skipchk = maniskip($manifest_skip_file);
if ($skipchk->($file)) { .. }
reads a MANIFEST.SKIP file with the name you give it (defaults to MANIFEST.SKIP in the current directory) and returns a CODE reference that tests whether a given filename should be skipped. Little gatekeeper behaviour, we stan πͺ
πΈ manicopy
manicopy(\%src, $dest_dir);
manicopy(\%src, $dest_dir, $how);
Copies the files that are the keys in %src over to $dest_dir. %src is typically whatever the maniread() function gave you back.
manicopy( maniread(), $dest_dir );
This function is genuinely useful for producing a directory tree identical to the intended distribution tree. β¨
$how lets you pick a different method of "copying". The valid values are:
"cp"β which actually copies the files"ln"β which creates hard links"best"β which mostly links the files but copies any symbolic link, so you get a tree with no symbolic links in it at all
"cp" is the default, bestie π
π¦ maniadd
maniadd({ $file => $comment, ...});
Adds an entry to an existing MANIFEST unless it's already there.
$file will be normalized (ie. Unixified).
UNIMPLEMENTED β οΈ like... it's just not there yet bestie, don't come for me
π MANIFEST
A list of files in the distribution, one file per line. The MANIFEST always uses Unix filepath conventions even if you're not on Unix. This means foo/bar style, not foo\bar. Slashes stay winning π
Anything between white space and an end of line inside a MANIFEST file counts as a comment. Any line beginning with # is also a comment. And starting with ExtUtils::Manifest 1.52, a filename may contain whitespace characters if it's enclosed in single quotes; single quotes or backslashes inside that filename must be backslash-escaped.
# this a comment
some/file
some/other/file comment about some/file
'some/third file' comment
π MANIFEST.SKIP
The file MANIFEST.SKIP may contain regular expressions of files that should be ignored by mkmanifest() and filecheck(). The regular expressions should appear one on each line. Blank lines and lines that start with "#" are skipped. Use "\#" if you need a regular expression to actually start with a "#".
For example:
# Version control files and dirs.
\bRCS\b
\bCVS\b
,v$
\B\.svn\b
# Makemaker generated files and dirs.
^MANIFEST\.
^Makefile$
^blib/
^MakeMaker-\d
# Temp, old and emacs backup files.
~$
\.old$
^#.*#$
^\.#
If no MANIFEST.SKIP file is found, a default set of skips gets used, similar to the example above. If you want nothing skipped, simply make an empty MANIFEST.SKIP file. Simple as that, no notes π
Inside your own MANIFEST.SKIP file, certain directives can be used to include the contents of other MANIFEST.SKIP files. At present, two such directives are recognized:
π«Ά #!include_default
This tells ExtUtils::Manifest to read the default MANIFEST.SKIP file and skip files accordingly, but not to include it in the local MANIFEST.SKIP. This is intended to skip files according to a system default, which can change over time without requiring any further changes to the distribution's MANIFEST.SKIP. Set it and forget it energy β¨
π #!include /Path/to/another/manifest.skip
This inserts the contents of the specified external file into the local MANIFEST.SKIP. This is intended for authors to have a central MANIFEST.SKIP file, and to include it with their various distributions. One file to rule them all π
The included contents will be inserted into the MANIFEST.SKIP file in between #!start included /path/to/manifest.skip and #!end included /path/to/manifest.skip markers. The original MANIFEST.SKIP is saved as MANIFEST.SKIP.bak.
β EXPORT_OK
&mkmanifest, &manicheck, &filecheck, &fullcheck, &maniread, and &manicopy are exportable.
π GLOBAL VARIABLES
$ExtUtils::Manifest::MANIFESTdefaults to"MANIFEST". Changing it results in both a differentMANIFESTand a differentMANIFEST.SKIPfile. This is useful if you want to maintain different distributions for different audiences (say a user version and a developer version including RCS).$ExtUtils::Manifest::Quietdefaults to0. If you set it to a true value, all functions act silently π€«.$ExtUtils::Manifest::Debugdefaults to0. If you set it to a true value, or ifPERL_MM_MANIFEST_DEBUGis true, debugging output will be produced. π
π DIAGNOSTICS π
All diagnostic output is sent to "STDERR". Every last bit of it.
"Not in MANIFEST:" fileβ is reported if a file is found which is not inMANIFEST."Skipping" fileβ is reported if a file is skipped due to an entry inMANIFEST.SKIP."No such file:" fileβ is reported if a file mentioned in aMANIFESTfile does not exist."MANIFEST:" $!β is reported ifMANIFESTcould not be opened. π"Added to MANIFEST:" fileβ is reported bymkmanifest()if $Verbose is set and a file is added toMANIFEST. $Verbose is set to 1 by default.
πΈ ENVIRONMENT πΈ
PERL_MM_MANIFEST_DEBUGβ Turns on debugging πβ¨
π¦ SEE ALSO π¦
ExtUtils::MakeMaker β which has handy targets for most of the functionality. Go say hi, it's mutuals bestie π«Ά
π AUTHOR π
Andreas Koenig "andreas.koenig@anima.de"
Currently maintained by the Perl Toolchain Gang. π
π COPYRIGHT AND LICENSE π
This software is copyright (c) 1996- by Andreas Koenig.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. π
okay that's the whole thing, you ate that read π
and for the record this page said its goodbyes from perl v5.44.0 on 2026-10-17 β mwah, go write your MANIFEST bestie π«Άβ¨
π¦ where this page comes from
- arch rolling: perl 5.44.0-1 Β· Artistic-1.0-Perl AND GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms