View on
MetaCPAN is shutting down
For details read Perl NOC. After June 25th this page will redirect to
Karen Etheridge > Dist-Zilla-Plugin-Git-2.043 > Dist::Zilla::Plugin::Git::NextVersion



Annotate this POD



New  5
Open  13
View/Report Bugs
Module Version: 2.043   Source  


Dist::Zilla::Plugin::Git::NextVersion - Provide a version number by bumping the last git release tag


version 2.043


In your dist.ini:

    first_version = 0.001       ; this is the default
    version_by_branch = 0       ; this is the default
    version_regexp  = ^v(.+)$   ; this is the default


This does the VersionProvider role. It finds the last version number from your Git tags, increments it using Version::Next, and uses the result as the version parameter for your distribution.

In addition, when making a release, it ensures that the version being released has not already been tagged. (The Git::Tag plugin has a similar check, but Git::Tag only checks for an exact match on the tag. Since Git::NextVersion knows how to extract version numbers from tags, it can find duplicates that Git::Tag would miss.)

The plugin accepts the following options:

You can also set the V environment variable to override the new version. This is useful if you need to bump to a specific version. For example, if the last tag is 0.005 and you want to jump to 1.000 you can set V = 1.000.

  $ V=1.000 dzil release

Because tracing history takes time, if you use the version_by_branch option, Git::NextVersion will create a .gitnxtver_cache file in your repository to track the highest version number that is an ancestor of the HEAD revision. You should add .gitnxtver_cache to your .gitignore file. It will automatically be pruned from the distribution.


Bugs may be submitted through the RT bug tracker (or

There is also a mailing list available for users of this distribution, at

There is also an irc channel available for users of this distribution, at #distzilla on

I am also usually active on irc, as 'ether' at


Jerome Quelin


This software is copyright (c) 2009 by Jerome Quelin.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

syntax highlighting: