File Coverage

blib/lib/Pod/Weaver/PluginBundle/BAREFOOT.pm
Criterion Covered Total %
statement 58 58 100.0
branch 1 2 50.0
condition 1 2 50.0
subroutine 20 20 100.0
pod n/a
total 80 82 97.5


line stmt bran cond sub pod time code
1 1     1   868728 use 5.012;
  1         2  
2 1     1   5 use MooseX::Declare;
  1         2  
  1         10  
3 1     1   1553 use Method::Signatures::Modifiers;
  1         2  
  1         10  
4              
5             class Pod::Weaver::PluginBundle::BAREFOOT
6 1     1   21982 {
  1     1   2  
  1     1   28  
  1     1   4011  
  1         2  
  1         7  
  1         4233  
  1         2  
  1         10  
  1         99  
7 1     1   42 use autodie 2.00 ;
  1         26  
  1         7  
8 1     1   2913 use MooseX::Has::Sugar ;
  1         1  
  1         9  
9 1     1   100 use MooseX::Types::Moose ':all' ;
  1         1  
  1         14  
10              
11             # Dependencies
12 1     1   5725 use Pod::Weaver 3.101635; # fixed ABSTRACT scanning
  1         28  
  1         24  
13 1     1   3 use Pod::Weaver::Config::Assembler;
  1         1  
  1         30  
14              
15 1     1   764 use Pod::Weaver::Plugin::WikiDoc ();
  1         83238  
  1         37  
16 1     1   568 use Pod::Elemental::Transformer::List 0.101620 ();
  1         12567  
  1         38  
17 1     1   666 use Pod::Weaver::Section::Support 1.001 ();
  1         172382  
  1         53  
18              
19              
20             our $VERSION = '0.05_01'; # TRIAL VERSION
21              
22              
23             my $bugtracker_content = <<'END';
24             This module is on GitHub. Feel free to fork and submit patches. Please note that I develop
25             via TDD (Test-Driven Development), so a patch that includes a failing test is much more
26             likely to get accepted (or least likely to get accepted more quickly).
27              
28             If you just want to report a problem or suggest a feature, that's okay too. You can create
29             an issue on GitHub here: {WEB}.
30             END
31              
32              
33 1 50   1   3096 method _exp { Pod::Weaver::Config::Assembler->expand_package($self) }
  15     15   422  
  15         25  
  15         29  
34              
35             method mvp_bundle_config ($class: ...)
36 1     1   4200 {
  1     1   1246  
37             # get payload (configurable parameters) from the dzil plugin bundle
38 1         38 my $payload = Dist::Zilla::PluginBundle::BAREFOOT->weaver_payload;
39              
40             # now set default values for them
41 1   50     4 $payload->{'repository_link'} //= 'both';
42              
43 1         2 my @plugins;
44 1         2 push @plugins, (
45             [ '@BAREFOOT/WikiDoc', _exp('-WikiDoc'), {} ],
46              
47             [ '@BAREFOOT/CorePrep', _exp('@CorePrep'), {} ],
48             [ '@BAREFOOT/Name', _exp('Name'), {} ],
49             [ '@BAREFOOT/Version', _exp('Version'), {
50             format => "This document describes version %v of %m.",
51             }
52             ],
53              
54             [ '@BAREFOOT/Synopsis', _exp('Generic'), { header => 'SYNOPSIS' } ],
55             [ '@BAREFOOT/Description', _exp('Generic'), { header => 'DESCRIPTION' } ],
56             [ '@BAREFOOT/Overview', _exp('Generic'), { header => 'OVERVIEW' } ],
57             );
58              
59 1         49 for my $plugin (
60             [ 'Attributes', _exp('Collect'), { command => 'attr' } ],
61             [ 'Methods', _exp('Collect'), { command => 'method' } ],
62             [ 'Functions', _exp('Collect'), { command => 'func' } ],
63             ){
64 3         31 $plugin->[2]->{'header'} = uc $plugin->[0];
65 3         4 push @plugins, $plugin;
66             }
67              
68             push @plugins, (
69             [ '@BAREFOOT/Leftovers', _exp('Leftovers'), {} ],
70             [ '@BAREFOOT/Support', _exp('Support'), {
71             perldoc => 1,
72             websites => 'none',
73             bugs => 'metadata',
74             bugs_content => $bugtracker_content,
75 1         10 repository_link => $payload->{'repository_link'},
76             repository_content => 'none',
77             }
78             ],
79             [ '@BAREFOOT/Authors', _exp('Authors'), {} ],
80             [ '@BAREFOOT/Legal', _exp('Legal'), {} ],
81             [ '@BAREFOOT/List', _exp('-Transformer'), { transformer => 'List' } ],
82             );
83              
84 1         44 return @plugins;
85             }
86              
87 1     1   5583 }
88              
89             # ABSTRACT: BAREFOOT's default Pod::Weaver config
90             # COPYRIGHT
91              
92             1;
93              
94             __END__
95              
96             =pod
97              
98             =head1 NAME
99              
100             Pod::Weaver::PluginBundle::BAREFOOT - BAREFOOT's default Pod::Weaver config
101              
102             =head1 VERSION
103              
104             This document describes version 0.05_01 of Pod::Weaver::PluginBundle::BAREFOOT.
105              
106             =head1 DESCRIPTION
107              
108             This is a L<Pod::Weaver> PluginBundle. It is roughly equivalent to the
109             following weaver.ini:
110              
111             [-WikiDoc]
112            
113             [@CorePrep]
114            
115             [Name]
116             [Version]
117            
118             [Generic / SYNOPSIS]
119             [Generic / DESCRIPTION]
120             [Generic / OVERVIEW]
121            
122             [Collect / ATTRIBUTES]
123             command = attr
124            
125             [Collect / METHODS]
126             command = method
127            
128             [Collect / FUNCTIONS]
129             command = func
130            
131             [Leftovers]
132             [Support]
133             perldoc = 1
134             websites = none
135             bugs = metadata
136             bugs_content = ... stuff (web only, email omitted) ...
137             repository_link = both
138             repository_content = none
139            
140             [Authors]
141             [Legal]
142            
143             [-Transformer]
144             transfomer = List
145              
146             =for Pod::Coverage mvp_bundle_config
147              
148             =head1 USAGE
149              
150             This PluginBundle is used automatically with the CE<lt>@BAREFOOTE<gt> L<Dist::Zilla>
151             plugin bundle.
152              
153             =head1 SEE ALSO
154              
155             =over
156              
157             =item *
158              
159             L<Pod::Weaver>
160              
161             =item *
162              
163             L<Pod::Weaver::Plugin::WikiDoc>
164              
165             =item *
166              
167             L<Pod::Elemental::Transformer::List>
168              
169             =item *
170              
171             L<Dist::Zilla::Plugin::PodWeaver>
172              
173             =back
174              
175             =head1 AUTHOR
176              
177             Buddy Burden <barefoot@cpan.org>
178              
179             =head1 COPYRIGHT AND LICENSE
180              
181             This software is Copyright (c) 2016 by Buddy Burden.
182              
183             This is free software, licensed under:
184              
185             The Artistic License 2.0 (GPL Compatible)
186              
187             =cut