File Coverage

lib/Dist/Zilla/Plugin/RewriteVersion/Sanitized.pm
Criterion Covered Total %
statement 17 17 100.0
branch n/a
condition n/a
subroutine 6 6 100.0
pod n/a
total 23 23 100.0


line stmt bran cond sub pod time code
1 3     3   1673393 use 5.008; # utf8
  3         11  
2 3     3   15 use strict;
  3         6  
  3         76  
3 3     3   13 use warnings;
  3         16  
  3         102  
4 3     3   905 use utf8;
  3         14  
  3         26  
5              
6             package Dist::Zilla::Plugin::RewriteVersion::Sanitized;
7              
8             our $VERSION = '0.001005';
9              
10             # ABSTRACT: RewriteVersion but force normalizing ENV{V} and other sources.
11              
12             our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY
13              
14 3     3   998 use Moose qw( extends with );
  3         426100  
  3         82  
15              
16             extends 'Dist::Zilla::Plugin::RewriteVersion';
17             with 'Dist::Zilla::Role::Version::Sanitize';
18              
19             __PACKAGE__->meta->make_immutable;
20 3     3   13933 no Moose;
  3         5  
  3         16  
21              
22             1;
23              
24             __END__
25              
26             =pod
27              
28             =encoding UTF-8
29              
30             =head1 NAME
31              
32             Dist::Zilla::Plugin::RewriteVersion::Sanitized - RewriteVersion but force normalizing ENV{V} and other sources.
33              
34             =head1 VERSION
35              
36             version 0.001005
37              
38             =head1 DESCRIPTION
39              
40             This is a subclass of L<< C<[RewriteVersion]>|Dist::Zilla::Plugin::RewriteVersion >> that applies version
41             sanitization from all the various possible input sources
42             ( Similar to L<< C<[Git::NextVersion::Sanitized]>|Dist::Zilla::Plugin::Git::NextVersion::Sanitized >> )
43             by applying L<< C<Dist::Zilla::Role::Version::Sanitize>|Dist::Zilla::Role::Version::Sanitize >> to it.
44              
45             Using this module instead of C<[RewriteVersion]> allows you to do
46              
47             V=2.6.0 dzil release
48              
49             And V will be interpreted as if you'd written C<V=2.006000>
50              
51             For details on the parameters this C<plugin> takes,
52             see L<< the documentation for Dist::Zilla::Role::Version::Sanitize|Dist::Zilla::Role::Version::Sanitize >>.
53              
54             =head1 SEE ALSO
55              
56             =over 4
57              
58             =item * L<< C<[RewriteVersion]>|Dist::Zilla::Plugin::RewriteVersion >>
59              
60             =item * L<< C<[RewriteVersion::Transitional]>|Dist::Zilla::Plugin::RewriteVersion::Transitional >>
61              
62             =back
63              
64             =head1 AUTHOR
65              
66             Kent Fredric <kentnl@cpan.org>
67              
68             =head1 COPYRIGHT AND LICENSE
69              
70             This software is copyright (c) 2015 by Kent Fredric <kentfredric@gmail.com>.
71              
72             This is free software; you can redistribute it and/or modify it under
73             the same terms as the Perl 5 programming language system itself.
74              
75             =cut