From: Peter Rabbitson Date: Thu, 24 Jul 2014 02:17:09 +0000 (+0200) Subject: Change version style/handling (doc coming up shortly) X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=e56f8014edf6718cf0d3f1f43c2a3080bcb7e2e3;p=dbsrgits%2FDBIx-Class-Historic.git Change version style/handling (doc coming up shortly) --- diff --git a/lib/DBIx/Class.pm b/lib/DBIx/Class.pm index 901023c..03c78fe 100644 --- a/lib/DBIx/Class.pm +++ b/lib/DBIx/Class.pm @@ -11,7 +11,7 @@ our $VERSION; # $VERSION declaration must stay up here, ahead of any other package # declarations, as to not confuse various modules attempting to determine # this ones version, whether that be s.c.o. or Module::Metadata, etc -$VERSION = '0.08270'; +$VERSION = '0.082700_01'; $VERSION = eval $VERSION if $VERSION =~ /_/; # numify for warning-free dev releases diff --git a/maint/Makefile.PL.inc/29_handle_version.pl b/maint/Makefile.PL.inc/29_handle_version.pl index 22d21fd..864fc67 100644 --- a/maint/Makefile.PL.inc/29_handle_version.pl +++ b/maint/Makefile.PL.inc/29_handle_version.pl @@ -1,28 +1,24 @@ -my $dbic_ver_re = qr/ (\d) \. (\d{2}) (\d{3}) (?: _ (\d{2}) )? /x; # not anchored!!! +my $dbic_ver_re = qr/ 0 \. (\d{2}) (\d{2}) (\d{2}) (?: _ (\d{2}) )? /x; # not anchored!!! my $version_string = Meta->version; my $version_value = eval $version_string; my ($v_maj, $v_min, $v_point, $v_dev) = $version_string =~ /^$dbic_ver_re$/ or die sprintf ( - "Invalid version %s (as specified in %s)\nCurrently valid version formats are M.VVPPP or M.VVPPP_DD\n", + "Invalid version %s (as specified in %s)\nCurrently valid version formats are 0.MMVVPP or 0.MMVVPP_DD\n", $version_string, Meta->{values}{version_from} || Meta->{values}{all_from} || 'Makefile.PL', ) ; -if ($v_maj != 0 or $v_min > 8) { +if ($v_maj > 8) { die "Illegal version $version_string - we are still in the 0.08 cycle\n" } -if ($v_point >= 300) { - die "Illegal version $version_string - we are still in the 0.082xx cycle\n" -} - Meta->makemaker_args->{DISTVNAME} = Meta->name . "-$version_string-TRIAL" if ( - # all odd releases *after* 0.08200 generate a -TRIAL, no exceptions - ( $v_point > 200 and int($v_point / 100) % 2 ) + # all odd releases *after* 0.089x generate a -TRIAL, no exceptions + ( $v_point > 89 ) ); @@ -32,13 +28,15 @@ if (keys %$tags) { my $shipped_versions; my $shipped_dev_versions; + my $legacy_re = qr/^ v 0 \. (\d{2}) (\d{2}) (\d) (?: _ (\d{2}) )? $/x; + for (keys %$tags) { - if ($_ =~ /^v$dbic_ver_re$/) { + if ($_ =~ /^v$dbic_ver_re$/ or $_ =~ $legacy_re ) { if (defined $4) { - $shipped_dev_versions->{"$1.$2$3$4"} = 1; + $shipped_dev_versions->{"0.$1$2$3$4"} = 1; } else { - $shipped_versions->{"$1.$2$3"} = 1; + $shipped_versions->{"0.$1$2$3"} = 1; } delete $tags->{$_}; }