Dist-Zilla-Plugin-Git
view release on metacpan or search on metacpan
lib/Dist/Zilla/Plugin/Git/Commit.pm view on Meta::CPAN
with 'Dist::Zilla::Role::Git::StringFormatter';
with 'Dist::Zilla::Role::GitConfig';
sub _git_config_mapping { +{
changelog => '%{changelog}s',
} }
# -- attributes
has commit_msg => ( is => 'ro', isa=>Str, default => 'v%V%n%n%c' );
has add_files_in => ( is => 'ro', isa=> ArrayRef[Path], coerce => 1, default => sub { [] });
has signoff => ( is => 'ro', isa => Bool, default => 0 );
# -- public methods
sub mvp_multivalue_args { qw( add_files_in ) }
around dump_config => sub
{
my $orig = shift;
lib/Dist/Zilla/Plugin/Git/NextVersion.pm view on Meta::CPAN
sub _versions_from_tags {
my ($regexp, $tags) = @_;
# WARNING: The quotes in "$1" are necessary, because version doesn't
# call get magic properly.
return [ sort map /$regexp/ ? try { version->parse("$1") } : (), @$tags ];
} # end _versions_from_tags
has _all_versions => (
is => 'ro', isa => ArrayRef,
init_arg => undef,
lazy => 1,
default => sub {
my $self = shift;
my $v = _versions_from_tags($self->version_regexp, [ $self->git->tag ]);
if ($self->logger->get_debug) {
$self->log_debug("Found version $_") for @$v;
}
$v;
}
( run in 0.248 second using v1.01-cache-2.11-cpan-9ff20fc0ed8 )