Alt-App-makepatch
view release on metacpan or search on metacpan
script/makepatch view on Meta::CPAN
By default, B<makepatch> will provide a few lines of progress
information, for example:
Extracting pkg-1.6.tar.gz to /tmp/mp21575.d/old...
Manifest MANIFEST for pkg-1.6 contains 1083 files.
Manifest MANIFEST for pkg-1.7 contains 1292 files.
Processing the filelists ...
Collecting patches ...
266 files need to be patched.
216 files and 8 directories need to be created.
7 files need to be removed.
B<applypatch> will provide no feedback information by default.
=head1 Makepatch arguments
B<makepatch> requires two arguments: I<old_src> and I<new_src>.
=over 4
=item I<old-src>
This is the name of either a single file or a directory that contains
copies of the older version of the target files; in other words,
copies of the files I<prior> to any modifications.
Alternatively, it may be the name of an archive that holds the files
to be processed. Allowable archive formats are gzipped tar (name ends
in "C<.tar.gz>" or "C<.tgz>"), bzipped tar (name ends in
"C<.tar.bz2>"), plain tar (name ends in "C<.tar>" and zip (name ends in
"C<.zip>").
=item I<new-src>
This is the name of either a single file or a directory that contains
copies of the newer version of the target files; in other words,
copies of the files I<after> the modifications have been made.
Alternatively, it may be the name of an archive that holds the files
to be processed.
=back
The patch script generated by B<makepatch> will take care of creating
new files and directories, update existing files, and remove files and
directories that are no longer present in the I<new-src> directory.
=head1 MANIFEST files
The purpose of a manifest file is to provide the list of files that
constitute a package. Manifest files are traditionally called
"C<MANIFEST>" and reside in the top level directory of the package.
Although there is no formal standard for the contents of manifest
files, B<makepatch> uses the following rules:
=over 4
=item *
If the second line from the manifest file looks like a separator line
(e.g. it is empty, or contains only dashes), it is discarded and so is
the first line.
=item *
Empty lines and lines that start with a C<#> are ignored.
=item *
If there are multiple space-separated "words" on a line, the first
word is considered to be the filename.
=back
=head2 Default treatment
By default, B<makepatch> looks for files named "C<MANIFEST>" in the
top level directories of the old and the new source trees. If these
files (or one of them) are found, they are used.
If no manifest file could be found, the package is assumed to consist
of all files in the directory.
The default name of the default manifest file can be modified with the
command line option "C<-automanifest>", see Section L<Command line
options>.
=head2 Explicitly naming of manifest files
Command line options "C<-oldmanifest>" and "C<-newmanifest>" can be
used to explicitly designate old and new manifest files. Option
"C<-manifest>" is a short way to set one manifest file for both the
old and new source trees.
=head2 Suppress manifest file processing
Command line option "C<-nomanifest>" can be used to suppress all
manifest file processing. The package is assumed to consist
of all files in the source directories.
=head1 Makepatch options
B<makepatch> takes several options to control its behaviour. Options
are usually specified on the command line, but B<makepatch> can take
options from three sources in the following order:
=over 4
=item *
Environment variable B<MAKEPATCHINIT>.
When this environment variable is set its contents are considered to
be command line options that are processed upon startup. All normal
options are allowed, plus one: B<-rcfile >I<filename>. Option
B<-rcfile> can be used to specify an alternate option file, see below.
=item *
Options files.
B<makepatch> first tries to process a file named B</etc/makepatchrc>.
(This is a Unix-ism.)
It is okay if this file is missing.
Next, B<makepatch> will process a file named B<.makepatchrc> in
the user's home directory, if it exists.
After processing this file, B<makepatch> will process a file named
B<.makepatchrc> in the current directory, if it exists. An alternative
name for this file can be specified with option B<-rcfile> in
environment variable B<MAKEPATCHINIT>. This is the only way to specify
an alternative options file name.
In all option files, empty lines and lines starting with C<;> or C<#>
are ignored. All other lines are considered to contain options exactly
as if they had been supplied on the command line.
( run in 3.145 seconds using v1.01-cache-2.11-cpan-2398b32b56e )