NAME

Dist::Zilla::Plugin::Git::DescribeVersion - Provide version using git-describe

VERSION

version 1.004

SYNOPSIS

In your dist.ini:

[Git::DescribeVersion]
match_pattern  = v[0-9]*     ; this is the default

DESCRIPTION

This performs the Dist::Zilla::Role::VersionProvider role. It uses Git::DescribeVersion to count the number of commits since the last tag (matching match_pattern) or since the initial commit, and uses the result as the version parameter for your distribution.

The plugin accepts the same options as "new" in Git::DescribeVersion. See "OPTIONS" in Git::DescribeVersion.

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

USAGE

Note: Since Git::DescribeVersion appends the third part to a two-part version tag (for example, a tag of v1.2 becomes v1.2.35) This plugin is not designed to be combined with Dist::Zilla::Plugin::Git::Tag (which will tag the repo with the generated version).

Instead it works better with manual tags. For example, you might manually increase the minor version (from v1.2 to v1.3) when a big feature is added or the API changes. Then each build will append the number of commits as the revision number (v1.3 becomes v1.3.28).

This is probably more useful for projects without formal releases. This is in fact the only way that the author still uses the module: For $work projects where builds are deployed often to a variety of internal environments.

For projects released to the world I suggest using the simple and logical Dist::Zilla::Plugin::Git::NextVersion which does work nicely with Dist::Zilla::Plugin::Git::Tag.

SEE ALSO

SUPPORT

Perldoc

You can find documentation for this module with the perldoc command.

perldoc Dist::Zilla::Plugin::Git::DescribeVersion

Websites

The following websites have more information about this module, and may be of help to you. As always, in addition to those websites please use your favorite search engine to discover more resources.

Bugs / Feature Requests

Please report any bugs or feature requests by email to bug-dist-zilla-plugin-git-describeversion at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Dist-Zilla-Plugin-Git-DescribeVersion. You will be automatically notified of any progress on the request by the system.

Source Code

https://github.com/rwstauner/Dist-Zilla-Plugin-Git-DescribeVersion

git clone https://github.com/rwstauner/Dist-Zilla-Plugin-Git-DescribeVersion.git

AUTHOR

Randy Stauner <rwstauner@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2010 by Randy Stauner.

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