add-pod-file - Utility to add new F<pod/*.pod> file to core distribution
=head1 USAGE
After C<make test_prep> has been run, call from top level of Perl 5 core
distribution:
perl Porting/add-pod-file \
--stub=<XXX> --section=<Z> --verbose
=head1 DESCRIPTION
This is a program which I<may> be helpful when a committer has to add a new
F<*.pod> file in the F<pod/> directory.
=head2 Prerequisites
This program assumes that committer has taken the following steps (in the
order listed):
=over 4
=item 1 You have run F<make test_prep>.
This is to guarantee that all files are properly positioned.
=item 2 You have placed a well-formatted F<.pod> file into the F<pod/> directory.
In the C<NAME> section of this file there is a single non-blank line which
consists of a string in the format C<STUB - ABSTRACT>, where C<STUB> is the
basename of the file without the C<.pod> suffix and C<ABSTRACT> is the short
description of the file. For example, a new file whose path is
F<pod/perlphonypod.pod> must have a C<NAME> section like this:
=head1 NAME
perlphonypod - This is phony POD
=back
F<pod/*.pod> files need entries in multiple locations to keep F<make
test_porting> happy. This program automates the formulation of I<most> of
those entries, but will need some assistance from the committer to work
properly. The committer will have to make a reasonable choice as to which
section of F<pod/perl.pod> the new F<.pod> file should be listed under.
The eligible sections are shown in the following table:
Command-Line Value Section in pod/perl.pod
O => 'Overview',
T => 'Tutorials',
R => 'Reference Manual',
I => 'Internals and C Language Interface',
H => 'History',
M => 'Miscellaneous',
L => 'Language-Specific',
P => 'Platform-Specific',
For a first pass, we'll put the new entry at the end of the C<^=head2> section
specified by the committer with the single-initial provided for command-line
switch C<section>.
=head2 Testing this program
=over 4
=item 1 Run F<configure> and F<make> in the source tree.
=item 2 Create a well formatted F<.pod> file somewhere on your system.
=item 3 Copy it into the source tree under F<pod>.
=item 4 Call the program as in L</USAGE> above.
=item 5 Call F<git diff> and examine results.
=item 6 Run F<make test_porting>.
=back
=head1 BUGS
When the argument provided to the C<--section> command-line switch is C<P> (for platform-specific), F<win32/pod.mak> is not getting updated -- but it's not clear whether it I<ought> to be updated.