Pod.pm

filter: Statementstmt 100% 27 / 27 Branchbran 50.0% 2 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 6 / 6 Podpod n/a totaltotal 94.5% 35 / 37 CC 1 SCAR 0.0
CC
1
Cov
94%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« Pod/MM/Constant.pm ↑ Summary
1 #
2 # This file is part of ASPEER::MakeMaker::Markdown::Pod.
3 #
4 # This software is copyright (c) 2026 by Andrew Speer <andrew.speer@isolutions.com.au>.
5 #
6 # This is free software; you can redistribute it and/or modify it under
7 # the same terms as the Perl 5 programming language system itself.
8 #
9 # Full license text is available at:
10 #
11 # <http://dev.perl.org/licenses/>
12 #
13 package ASPEER::MakeMaker::Markdown::Pod;
14  
15  
16 # Compiler pragma and package variables
17 #
18 4 ▶use strict qw(vars);
Subroutine BEGIN: called CC=1 SCAR=0.0
19 4 ▶use vars qw($VERSION $VERSION_GIT_SHA $AUTHORITY @ISA);
Subroutine BEGIN: called CC=1 SCAR=0.0
20 4 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
21  
22  
23 # Inherit the shared MakeMaker integration and keep the historic processing
24 # API as a compatibility facade.
25 #
26 4 ▶use ASPEER::MakeMaker ();
Subroutine BEGIN: called CC=1 SCAR=0.0
27 4 ▶use ASPEER::MakeMaker::Markdown::Pod::MM ();
Subroutine BEGIN: called CC=1 SCAR=0.0
28 4 ▶use Markdown::Pod::Embed ();
Subroutine BEGIN: called CC=1 SCAR=0.0
29 4 @ISA=qw(ASPEER::MakeMaker Markdown::Pod::Embed);
30  
31  
32 # Version information
33 #
34 4 $AUTHORITY='cpan:ASPEER';
35 4 $VERSION='1.012';
36 4 ▶$VERSION_GIT_SHA=do { local(@ARGV, $/, $_); @ARGV=($_=__FILE__.'.sha'); <> if -f $_ };
Branch: 1 branch
BranchTrueFalseTotal
if -f $_ 0 4 4
37 4 ▶chomp($VERSION_GIT_SHA) if defined($VERSION_GIT_SHA);
Branch: 1 branch
BranchTrueFalseTotal
if defined $ASPEER::MakeMaker::Markdown::Pod::VERSION_GIT_SHA 0 4 4
38  
39  
40 # Done
41 #
42 4 1;
43  
44  
45 __END__
46  
47 =begin markdown
48  
49 # NAME
50  
51 ASPEER::MakeMaker::Markdown::Pod - MakeMaker integration for Markdown-maintained POD
52  
53 # SYNOPSIS
54  
55 In `Makefile.PL`:
56  
57 ```perl
58 use ExtUtils::MakeMaker;
59 use ASPEER::MakeMaker::Markdown::Pod;
60  
61 WriteMakefile(
62 NAME => 'Example',
63 VERSION_FROM => 'lib/Example.pm',
64 );
65 ```
66  
67 This adds `doc` and `readme` targets to the generated Makefile.
68  
69 For optional integration, load and import the module before `WriteMakefile`:
70  
71 ```perl
72 use ExtUtils::MakeMaker;
73  
74 eval {
75 require ASPEER::MakeMaker::Markdown::Pod;
76 ASPEER::MakeMaker::Markdown::Pod->import();
77 1;
78 };
79  
80 WriteMakefile(
81 NAME => 'Example',
82 VERSION_FROM => 'lib/Example.pm',
83 );
84 ```
85  
86 If the optional module cannot be loaded, MakeMaker continues without the
87 additional lifecycle hooks and documentation targets. The equivalent explicit
88 command-line activation is:
89  
90 ```text
91 perl -MASPEER::MakeMaker::Markdown::Pod Makefile.PL
92 ```
93  
94 # DESCRIPTION
95  
96 `ASPEER::MakeMaker::Markdown::Pod` integrates documentation maintenance and the project's
97 established distribution conventions with `ExtUtils::MakeMaker`. Importing it
98 from `Makefile.PL` installs the MakeMaker lifecycle hooks used to configure the
99 generated Makefile, package metadata and install map, Git-SHA provenance, and
100 documentation targets. The generated global `PERLRUN` preserves
101 the active local library paths and MakeMaker extensions.
102  
103 The responsibilities are deliberately separated:
104  
105 - `ASPEER::MakeMaker::Markdown::Pod` inherits the common MakeMaker behavior
106 from `ASPEER::MakeMaker`.
107 - `ASPEER::MakeMaker::MM::Import` installs and implements the MakeMaker
108 lifecycle hooks.
109 - `ASPEER::MakeMaker::Markdown::Pod::MM` generates and executes the `doc` and `readme`
110 targets.
111 - `Docbook::Convert::Pandoc` discovers DocBook articles beneath `doc/` and
112 converts them to sibling Markdown files.
113 - `Markdown::Pod::Embed` selects Markdown, converts it to POD, and updates Perl
114 source files.
115  
116 The `doc` target discovers DocBook articles beneath `doc/` independently of
117 `MANIFEST`, converts them to sibling Markdown files, and then processes Markdown
118 sidecars listed in `MANIFEST` for matching Perl modules, scripts, and declared
119 executable files. `readme` renders the best available README Markdown source as
120 plain text.
121  
122 # PROCESSOR COMPATIBILITY
123  
124 For compatibility with earlier releases, this package inherits the processing
125 methods supplied by `Markdown::Pod::Embed`. New code that only converts or
126 updates Markdown/POD should use `Markdown::Pod::Embed` directly; it does not
127 need MakeMaker and does not install MakeMaker hooks.
128  
129 # ERRORS
130  
131 MakeMaker hook errors and target failures are fatal. Importing this module from
132 a program other than `Makefile.PL` does not alter `ExtUtils::MakeMaker`.
133  
134 # SEE ALSO
135  
136 `ASPEER::MakeMaker`, `ASPEER::MakeMaker::Markdown::Pod::MM`,
137 `ASPEER::MakeMaker::MM::Import`,
138 `Markdown::Pod::Embed`, `ExtUtils::MakeMaker`
139  
140 # AUTHOR
141  
142 Andrew Speer <andrew.speer@isolutions.com.au>
143  
144 # LICENSE and COPYRIGHT
145  
146 This file is part of ASPEER::MakeMaker::Markdown::Pod.
147  
148 This software is copyright (c) 2026 by Andrew Speer <andrew.speer@isolutions.com.au>.
149  
150 This is free software; you can redistribute it and/or modify it under
151 the same terms as the Perl 5 programming language system itself.
152  
153 Full license text is available at:
154  
155 <http://dev.perl.org/licenses/>
156  
157  
158 =end markdown
159  
160  
161 =head1 NAME
162  
163 ASPEER::MakeMaker::Markdown::Pod - MakeMaker integration for Markdown-maintained POD
164  
165  
166 =head1 SYNOPSIS
167  
168 In C<Makefile.PL>:
169  
170  
171 use ExtUtils::MakeMaker;
172 use ASPEER::MakeMaker::Markdown::Pod;
173  
174 WriteMakefile(
175 NAME => 'Example',
176 VERSION_FROM => 'lib/Example.pm',
177 );
178 This adds C<doc> and C<readme> targets to the generated Makefile.
179  
180 For optional integration, load and import the module before C<WriteMakefile>:
181  
182  
183 use ExtUtils::MakeMaker;
184  
185 eval {
186 require ASPEER::MakeMaker::Markdown::Pod;
187 ASPEER::MakeMaker::Markdown::Pod->import();
188 1;
189 };
190  
191 WriteMakefile(
192 NAME => 'Example',
193 VERSION_FROM => 'lib/Example.pm',
194 );
195 If the optional module cannot be loaded, MakeMaker continues without the
196 additional lifecycle hooks and documentation targets. The equivalent explicit
197 command-line activation is:
198  
199  
200 perl -MASPEER::MakeMaker::Markdown::Pod Makefile.PL
201  
202 =head1 DESCRIPTION
203  
204 C<ASPEER::MakeMaker::Markdown::Pod> integrates documentation maintenance and the project's
205 established distribution conventions with C<ExtUtils::MakeMaker>. Importing it
206 from C<Makefile.PL> installs the MakeMaker lifecycle hooks used to configure the
207 generated Makefile, package metadata and install map, Git-SHA provenance, and
208 documentation targets. The generated global C<PERLRUN> preserves
209 the active local library paths and MakeMaker extensions.
210  
211 The responsibilities are deliberately separated:
212  
213 =over
214  
215 =item -
216  
217 C<ASPEER::MakeMaker::Markdown::Pod> inherits the common MakeMaker behavior
218 from C<ASPEER::MakeMaker>.
219  
220  
221 =item -
222  
223 C<ASPEER::MakeMaker::MM::Import> installs and implements the MakeMaker
224 lifecycle hooks.
225  
226  
227 =item -
228  
229 C<ASPEER::MakeMaker::Markdown::Pod::MM> generates and executes the C<doc> and C<readme>
230 targets.
231  
232  
233 =item -
234  
235 C<Docbook::Convert::Pandoc> discovers DocBook articles beneath C<doc/> and
236 converts them to sibling Markdown files.
237  
238  
239 =item -
240  
241 C<Markdown::Pod::Embed> selects Markdown, converts it to POD, and updates Perl
242 source files.
243  
244  
245 =back
246  
247 The C<doc> target discovers DocBook articles beneath C<doc/> independently of
248 C<MANIFEST>, converts them to sibling Markdown files, and then processes Markdown
249 sidecars listed in C<MANIFEST> for matching Perl modules, scripts, and declared
250 executable files. C<readme> renders the best available README Markdown source as
251 plain text.
252  
253  
254 =head1 PROCESSOR COMPATIBILITY
255  
256 For compatibility with earlier releases, this package inherits the processing
257 methods supplied by C<Markdown::Pod::Embed>. New code that only converts or
258 updates Markdown/POD should use C<Markdown::Pod::Embed> directly; it does not
259 need MakeMaker and does not install MakeMaker hooks.
260  
261  
262 =head1 ERRORS
263  
264 MakeMaker hook errors and target failures are fatal. Importing this module from
265 a program other than C<Makefile.PL> does not alter C<ExtUtils::MakeMaker>.
266  
267  
268 =head1 SEE ALSO
269  
270 C<ASPEER::MakeMaker>, C<ASPEER::MakeMaker::Markdown::Pod::MM>,
271 C<ASPEER::MakeMaker::MM::Import>,
272 C<Markdown::Pod::Embed>, C<ExtUtils::MakeMaker>
273  
274  
275 =head1 AUTHOR
276  
277 Andrew Speer L<mailto:andrew.speer@isolutions.com.au>
278  
279  
280 =head1 LICENSE AND COPYRIGHT
281  
282 This file is part of ASPEER::MakeMaker::Markdown::Pod.
283  
284 This software is copyright (c) 2026 by Andrew Speer
285 L<mailto:andrew.speer@isolutions.com.au>.
286  
287 This is free software; you can redistribute it and/or modify it under
288 the same terms as the Perl 5 programming language system itself.
289  
290 Full license text is available at:
291  
292 L<http://dev.perl.org/licenses/>
293  
294 =cut
« Pod/MM/Constant.pm ↑ Summary