r69156 - in /trunk/libdist-zilla-plugin-git-perl: ./ debian/ lib/Dist/Zilla/Plugin/ lib/Dist/Zilla/Plugin/Git/ lib/Dist/Zilla/PluginBundle/ lib/Dist/Zilla/Role/Git/ t/ t/commit-build-custom/ t/commit-dirtydir/ t/lib/

ghedo-guest at users.alioth.debian.org ghedo-guest at users.alioth.debian.org
Sun Feb 20 17:35:55 UTC 2011


Author: ghedo-guest
Date: Sun Feb 20 17:35:35 2011
New Revision: 69156

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=69156
Log:
new upstream release

Added:
    trunk/libdist-zilla-plugin-git-perl/t/2-commit-dirtydir.t
      - copied unchanged from r69155, branches/upstream/libdist-zilla-plugin-git-perl/current/t/2-commit-dirtydir.t
    trunk/libdist-zilla-plugin-git-perl/t/commit-dirtydir/
      - copied from r69155, branches/upstream/libdist-zilla-plugin-git-perl/current/t/commit-dirtydir/
    trunk/libdist-zilla-plugin-git-perl/t/lib/
      - copied from r69155, branches/upstream/libdist-zilla-plugin-git-perl/current/t/lib/
Modified:
    trunk/libdist-zilla-plugin-git-perl/Build.PL
    trunk/libdist-zilla-plugin-git-perl/Changes
    trunk/libdist-zilla-plugin-git-perl/MANIFEST
    trunk/libdist-zilla-plugin-git-perl/META.json
    trunk/libdist-zilla-plugin-git-perl/META.yml
    trunk/libdist-zilla-plugin-git-perl/README
    trunk/libdist-zilla-plugin-git-perl/debian/changelog
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Check.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Commit.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/CommitBuild.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Init.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/NextVersion.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Push.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Tag.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/PluginBundle/Git.pm
    trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Role/Git/DirtyFiles.pm
    trunk/libdist-zilla-plugin-git-perl/t/000-report-versions-tiny.t
    trunk/libdist-zilla-plugin-git-perl/t/2-commit-build-custom.t
    trunk/libdist-zilla-plugin-git-perl/t/commit-build-custom/dist.ini

Modified: trunk/libdist-zilla-plugin-git-perl/Build.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/Build.PL?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/Build.PL (original)
+++ trunk/libdist-zilla-plugin-git-perl/Build.PL Sun Feb 20 17:35:35 2011
@@ -7,7 +7,9 @@
 
 my %module_build_args = (
   'build_requires' => {
+    'Dist::Zilla::Role::Releaser' => '0',
     'Dist::Zilla::Tester' => '0',
+    'File::Copy' => '0',
     'File::Copy::Recursive' => '0',
     'File::Find' => '0',
     'File::pushd' => '0',
@@ -24,7 +26,7 @@
     'Jerome Quelin'
   ],
   'dist_name' => 'Dist-Zilla-Plugin-Git',
-  'dist_version' => '1.110330',
+  'dist_version' => '1.110500',
   'license' => 'perl',
   'module_name' => 'Dist::Zilla::Plugin::Git',
   'recommends' => {},
@@ -50,6 +52,7 @@
     'Moose::Role' => '0',
     'MooseX::Has::Sugar' => '0',
     'MooseX::Types::Moose' => '0',
+    'Path::Class::Dir' => '0',
     'String::Formatter' => '0',
     'Version::Next' => '0',
     'namespace::autoclean' => '0.09',

Modified: trunk/libdist-zilla-plugin-git-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/Changes?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/Changes (original)
+++ trunk/libdist-zilla-plugin-git-perl/Changes Sun Feb 20 17:35:35 2011
@@ -1,4 +1,13 @@
 Revision history for Dist::Zilla::Plugin::Git
+
+1.110500  2011-02-19 12:43:19 Europe/Paris
+ - add 'add_files_in' to Commit so you can commit an entire dir (Apocalypse)
+   If you need the same concept for Check please let us know!
+
+1.110480  2011-02-17 18:03:06 Europe/Paris
+ - CommitBuild support for release_message (nigel metheringham)
+ - Also supports %v & %t format tags, more appropriate for message on
+   commit build of the released package (nigel metheringham)
 
 1.110330  2011-02-02 10:36:33 Europe/Paris
  - fix rt#62484 - add a link to Git::NextVersion in main documentation

Modified: trunk/libdist-zilla-plugin-git-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/MANIFEST?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/MANIFEST (original)
+++ trunk/libdist-zilla-plugin-git-perl/MANIFEST Sun Feb 20 17:35:35 2011
@@ -27,6 +27,7 @@
 t/1-check.t
 t/2-commit-build-custom.t
 t/2-commit-build.t
+t/2-commit-dirtydir.t
 t/2-commit-ws.t
 t/2-commit.t
 t/3-tag.t
@@ -41,10 +42,13 @@
 t/commit-build-custom/dist.ini
 t/commit-build/Changes
 t/commit-build/dist.ini
+t/commit-dirtydir/Changes
+t/commit-dirtydir/dist.ini
 t/commit-ws/Changes
 t/commit-ws/dist.ini
 t/commit/Changes
 t/commit/dist.ini
+t/lib/Dist/Zilla/Plugin/MyTestArchiver.pm
 t/push-multi/Changes
 t/push-multi/dist.ini
 t/push/Changes

Modified: trunk/libdist-zilla-plugin-git-perl/META.json
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/META.json?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/META.json (original)
+++ trunk/libdist-zilla-plugin-git-perl/META.json Sun Feb 20 17:35:35 2011
@@ -46,6 +46,7 @@
             "Moose::Role" : 0,
             "MooseX::Has::Sugar" : 0,
             "MooseX::Types::Moose" : 0,
+            "Path::Class::Dir" : 0,
             "String::Formatter" : 0,
             "Version::Next" : 0,
             "namespace::autoclean" : "0.09",
@@ -55,7 +56,9 @@
       },
       "test" : {
          "requires" : {
+            "Dist::Zilla::Role::Releaser" : 0,
             "Dist::Zilla::Tester" : 0,
+            "File::Copy" : 0,
             "File::Copy::Recursive" : 0,
             "File::Find" : 0,
             "File::pushd" : 0,
@@ -68,43 +71,43 @@
    "provides" : {
       "Dist::Zilla::Plugin::Git" : {
          "file" : "lib/Dist/Zilla/Plugin/Git.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::Check" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/Check.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::Commit" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/Commit.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::CommitBuild" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/CommitBuild.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::Init" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/Init.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::NextVersion" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/NextVersion.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::Push" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/Push.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Plugin::Git::Tag" : {
          "file" : "lib/Dist/Zilla/Plugin/Git/Tag.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::PluginBundle::Git" : {
          "file" : "lib/Dist/Zilla/PluginBundle/Git.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       },
       "Dist::Zilla::Role::Git::DirtyFiles" : {
          "file" : "lib/Dist/Zilla/Role/Git/DirtyFiles.pm",
-         "version" : "1.110330"
+         "version" : "1.110500"
       }
    },
    "release_status" : "stable",
@@ -121,7 +124,7 @@
       },
       "x_MailingList" : "http://www.listbox.com/subscribe/?list_id=139292"
    },
-   "version" : "1.110330",
+   "version" : "1.110500",
    "x_Dist_Zilla" : {
       "plugins" : [
          {

Modified: trunk/libdist-zilla-plugin-git-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/META.yml?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/META.yml (original)
+++ trunk/libdist-zilla-plugin-git-perl/META.yml Sun Feb 20 17:35:35 2011
@@ -3,7 +3,9 @@
 author:
   - 'Jerome Quelin'
 build_requires:
+  Dist::Zilla::Role::Releaser: 0
   Dist::Zilla::Tester: 0
+  File::Copy: 0
   File::Copy::Recursive: 0
   File::Find: 0
   File::pushd: 0
@@ -23,34 +25,34 @@
 provides:
   Dist::Zilla::Plugin::Git:
     file: lib/Dist/Zilla/Plugin/Git.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::Check:
     file: lib/Dist/Zilla/Plugin/Git/Check.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::Commit:
     file: lib/Dist/Zilla/Plugin/Git/Commit.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::CommitBuild:
     file: lib/Dist/Zilla/Plugin/Git/CommitBuild.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::Init:
     file: lib/Dist/Zilla/Plugin/Git/Init.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::NextVersion:
     file: lib/Dist/Zilla/Plugin/Git/NextVersion.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::Push:
     file: lib/Dist/Zilla/Plugin/Git/Push.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Plugin::Git::Tag:
     file: lib/Dist/Zilla/Plugin/Git/Tag.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::PluginBundle::Git:
     file: lib/Dist/Zilla/PluginBundle/Git.pm
-    version: 1.110330
+    version: 1.110500
   Dist::Zilla::Role::Git::DirtyFiles:
     file: lib/Dist/Zilla/Role/Git/DirtyFiles.pm
-    version: 1.110330
+    version: 1.110500
 requires:
   Class::MOP: 0
   Cwd: 0
@@ -72,6 +74,7 @@
   Moose::Role: 0
   MooseX::Has::Sugar: 0
   MooseX::Types::Moose: 0
+  Path::Class::Dir: 0
   String::Formatter: 0
   Version::Next: 0
   namespace::autoclean: 0.09
@@ -82,7 +85,7 @@
   homepage: http://search.cpan.org/dist/Dist-Zilla-Plugin-Git/
   repository: git://github.com/jquelin/dist-zilla-plugin-git.git
   x_MailingList: http://www.listbox.com/subscribe/?list_id=139292
-version: 1.110330
+version: 1.110500
 x_Dist_Zilla:
   plugins:
     -

Modified: trunk/libdist-zilla-plugin-git-perl/README
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/README?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/README (original)
+++ trunk/libdist-zilla-plugin-git-perl/README Sun Feb 20 17:35:35 2011
@@ -1,7 +1,7 @@
 
 
 This archive contains the distribution Dist-Zilla-Plugin-Git,
-version 1.110330:
+version 1.110500:
 
   update your git repository after release
 

Modified: trunk/libdist-zilla-plugin-git-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/debian/changelog?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/debian/changelog (original)
+++ trunk/libdist-zilla-plugin-git-perl/debian/changelog Sun Feb 20 17:35:35 2011
@@ -1,3 +1,9 @@
+libdist-zilla-plugin-git-perl (1.110500-1) UNRELEASED; urgency=low
+
+  * New upstream release
+
+ -- Alessandro Ghedini <al3xbio at gmail.com>  Sun, 20 Feb 2011 18:31:53 +0100
+
 libdist-zilla-plugin-git-perl (1.110330-1) unstable; urgency=low
 
   * Initial Release. (Closes: #606862)

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::VERSION = '1.110500';
 }
 # ABSTRACT: update your git repository after release
 
@@ -28,7 +28,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 DESCRIPTION
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Check.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Check.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Check.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Check.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git::Check;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::Check::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::Check::VERSION = '1.110500';
 }
 # ABSTRACT: check your git repository before releasing
 
@@ -78,7 +78,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Commit.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Commit.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Commit.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Commit.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git::Commit;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::Commit::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::Commit::VERSION = '1.110500';
 }
 # ABSTRACT: commit dirty files
 
@@ -21,6 +21,7 @@
 use Moose;
 use MooseX::Has::Sugar;
 use MooseX::Types::Moose qw{ Str };
+use Path::Class::Dir ();
 
 use String::Formatter method_stringf => {
   -as => '_format_string',
@@ -45,9 +46,11 @@
 
 has commit_msg => ( ro, isa=>Str, default => 'v%v%n%n%c' );
 has time_zone  => ( ro, isa=>Str, default => 'local' );
-
+has add_files_in  => ( ro, isa=>'ArrayRef[Str]', default => sub { [] } );
 
 # -- public methods
+
+sub mvp_multivalue_args { qw( add_files_in ) }
 
 sub after_release {
     my $self = shift;
@@ -59,7 +62,22 @@
     # otherwise before_release would have failed, ending the release
     # process.
     @output = sort { lc $a cmp lc $b } $self->list_dirty_files($git, 1);
-    return unless @output;
+
+    # add any other untracked files to the commit list
+    if ( @{ $self->add_files_in } ) {
+        my @untracked_files = $git->ls_files( { others=>1, 'exclude-standard'=>1 } );
+        foreach my $f ( @untracked_files ) {
+            foreach my $path ( @{ $self->add_files_in } ) {
+                if ( Path::Class::Dir->new( $path )->subsumes( $f ) ) {
+                    push( @output, $f );
+                    last;
+                }
+            }
+        }
+    }
+
+    # if nothing to commit, we're done!
+    return unless @output;    
 
     # write commit message in a temp file
     my ($fh, $filename) = tempfile( 'DZP-git.XXXX', UNLINK => 1 );
@@ -111,7 +129,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 
@@ -137,6 +155,14 @@
 modified.  This option may appear multiple times.  The default
 list is F<dist.ini> and the changelog file given by C<changelog>.
 
+=item * add_files_in - a path that will have its new files checked in.
+This option may appear multiple times. This is used to add files
+generated during build-time to the repository, for example. The default
+list is empty.
+
+Note: The files have to be generated between those phases: BeforeRelease
+E<lt>-E<gt> AfterRelease, and after Git::Check + before Git::Commit.
+
 =item * commit_msg - the commit message to use. Defaults to
 C<v%v%n%n%c>, meaning the version number and the list of changes.
 
@@ -184,7 +210,7 @@
 This method returns the commit message.  The default implementation
 reads the Changes file to get the list of changes in the just-released version.
 
-=for Pod::Coverage after_release
+=for Pod::Coverage after_release mvp_multivalue_args
 
 =head1 AUTHOR
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/CommitBuild.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/CommitBuild.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/CommitBuild.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/CommitBuild.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git::CommitBuild;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::CommitBuild::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::CommitBuild::VERSION = '1.110500';
 }
 # ABSTRACT: checkin build results on separate branch
 
@@ -35,9 +35,11 @@
 	method_stringf => {
 		-as   => '_format_message',
 		codes => {
-			b => sub { (shift->name_rev( '--name-only', 'HEAD' ))[0] },
-			h => sub { (shift->rev_parse( '--short',    'HEAD' ))[0] },
-			H => sub { (shift->rev_parse('HEAD'))[0] },
+			b => sub { (shift->_git->name_rev( '--name-only', 'HEAD' ))[0] },
+			h => sub { (shift->_git->rev_parse( '--short',    'HEAD' ))[0] },
+			H => sub { (shift->_git->rev_parse('HEAD'))[0] },
+		    t => sub { shift->zilla->is_trial ? '-TRIAL' : '' },
+		    v => sub { shift->zilla->version },
 		}
 	}
 );
@@ -49,7 +51,13 @@
 has branch  => ( ro, isa => Str, default => 'build/%b', required => 1 );
 has release_branch  => ( ro, isa => Str, required => 0 );
 has message => ( ro, isa => Str, default => 'Build results of %h (on %b)', required => 1 );
+has release_message => ( ro, isa => Str, lazy => 1, builder => '_build_release_message' );
 has build_root => ( rw );
+has _git => (rw, weak_ref => 1);
+
+# -- attribute builders
+
+sub _build_release_message { return shift->message; }
 
 # -- role implementation
 
@@ -60,22 +68,23 @@
     # the 'after_release' stage
     $self->build_root( $args->{build_root} );
 
-    $self->_commit_build( $args, $self->branch );
+    $self->_commit_build( $args, $self->branch, $self->message );
 }
 
 sub after_release {
     my ( $self, $args) = @_;
 
-    $self->_commit_build( $args, $self->release_branch );
+    $self->_commit_build( $args, $self->release_branch, $self->release_message );
 }
 
 sub _commit_build {
-    my ( $self, undef, $branch ) = @_;
+    my ( $self, undef, $branch, $message ) = @_;
 
     return unless $branch;
 
     my $tmp_dir = File::Temp->newdir( CLEANUP => 1) ;
     my $src     = Git::Wrapper->new('.');
+    $self->_git($src);
 
     my $dir = rel2abs( $self->build_root );
 
@@ -114,7 +123,7 @@
         #
         my ($fh, $filename) = File::Temp::tempfile();
         $fh->autoflush(1);
-        print $fh _format_message( $self->message, $src );
+        print $fh _format_message( $message, $self );
 
         my @args=('git', 'commit-tree', $tree, map { ( -p => $_ ) } @parents);
         push @args,'<'.$filename;
@@ -139,7 +148,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 
@@ -163,11 +172,14 @@
 =over 4
 
 =item * branch - L<String::Formatter> string for where to commit the
-build contents
+build contents.
 
 A single formatting code (C<%b>) is defined for this attribute and will be
 substituted with the name of the current branch in your git repository.
 
+Defaults to C<build/%b>, but if set explicitly to an empty string
+causes no build contents checkin to be made.
+
 =item * release_branch - L<String::Formatter> string for where to commit the
 build contents
 
@@ -177,7 +189,7 @@
 =item * message - L<String::Formatter> string for what commit message
 to use when committing the results of the build.
 
-This option supports three formatting codes:
+This option supports five formatting codes:
 
 =over 4
 
@@ -187,7 +199,15 @@
 
 =item * C<%h> - Abbreviated commit hash
 
+=item * C<%v> - The release version number
+
+=item * C<%t> - The string "-TRIAL" if this is a trial release
+
 =back
+
+=item * release_message - L<String::Formatter> string for what
+commit message to use when committing the results of the release.
+Defaults to the same as C<message>.
 
 =back
 
@@ -210,3 +230,4 @@
 
 __END__
 
+

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Init.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Init.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Init.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Init.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git::Init;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::Init::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::Init::VERSION = '1.110500';
 }
 # ABSTRACT: initialize git repository on dzil new
 
@@ -88,7 +88,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/NextVersion.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/NextVersion.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/NextVersion.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/NextVersion.pm Sun Feb 20 17:35:35 2011
@@ -11,7 +11,7 @@
 
 package Dist::Zilla::Plugin::Git::NextVersion;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::NextVersion::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::NextVersion::VERSION = '1.110500';
 }
 # ABSTRACT: provide a version number by bumping the last git release tag
 
@@ -75,7 +75,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Push.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Push.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Push.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Push.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git::Push;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::Push::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::Push::VERSION = '1.110500';
 }
 # ABSTRACT: push current branch
 
@@ -59,7 +59,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Tag.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Tag.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Tag.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Plugin/Git/Tag.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Plugin::Git::Tag;
 BEGIN {
-  $Dist::Zilla::Plugin::Git::Tag::VERSION = '1.110330';
+  $Dist::Zilla::Plugin::Git::Tag::VERSION = '1.110500';
 }
 # ABSTRACT: tag the new version
 
@@ -94,7 +94,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/PluginBundle/Git.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/PluginBundle/Git.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/PluginBundle/Git.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/PluginBundle/Git.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::PluginBundle::Git;
 BEGIN {
-  $Dist::Zilla::PluginBundle::Git::VERSION = '1.110330';
+  $Dist::Zilla::PluginBundle::Git::VERSION = '1.110500';
 }
 # ABSTRACT: all git plugins in one go
 
@@ -66,7 +66,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 SYNOPSIS
 

Modified: trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Role/Git/DirtyFiles.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Role/Git/DirtyFiles.pm?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Role/Git/DirtyFiles.pm (original)
+++ trunk/libdist-zilla-plugin-git-perl/lib/Dist/Zilla/Role/Git/DirtyFiles.pm Sun Feb 20 17:35:35 2011
@@ -12,7 +12,7 @@
 
 package Dist::Zilla::Role::Git::DirtyFiles;
 BEGIN {
-  $Dist::Zilla::Role::Git::DirtyFiles::VERSION = '1.110330';
+  $Dist::Zilla::Role::Git::DirtyFiles::VERSION = '1.110500';
 }
 # ABSTRACT: provide the allow_dirty & changelog attributes
 
@@ -70,7 +70,7 @@
 
 =head1 VERSION
 
-version 1.110330
+version 1.110500
 
 =head1 DESCRIPTION
 

Modified: trunk/libdist-zilla-plugin-git-perl/t/000-report-versions-tiny.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/t/000-report-versions-tiny.t?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/t/000-report-versions-tiny.t (original)
+++ trunk/libdist-zilla-plugin-git-perl/t/000-report-versions-tiny.t Sun Feb 20 17:35:35 2011
@@ -57,8 +57,10 @@
 eval { $v .= pmver('Dist::Zilla::Role::AfterRelease','any version') };
 eval { $v .= pmver('Dist::Zilla::Role::BeforeRelease','any version') };
 eval { $v .= pmver('Dist::Zilla::Role::PluginBundle','any version') };
+eval { $v .= pmver('Dist::Zilla::Role::Releaser','any version') };
 eval { $v .= pmver('Dist::Zilla::Role::VersionProvider','any version') };
 eval { $v .= pmver('Dist::Zilla::Tester','any version') };
+eval { $v .= pmver('File::Copy','any version') };
 eval { $v .= pmver('File::Copy::Recursive','any version') };
 eval { $v .= pmver('File::Find','any version') };
 eval { $v .= pmver('File::Spec::Functions','any version') };
@@ -74,6 +76,7 @@
 eval { $v .= pmver('MooseX::Has::Sugar','any version') };
 eval { $v .= pmver('MooseX::Types::Moose','any version') };
 eval { $v .= pmver('Path::Class','any version') };
+eval { $v .= pmver('Path::Class::Dir','any version') };
 eval { $v .= pmver('String::Formatter','any version') };
 eval { $v .= pmver('Test::Exception','any version') };
 eval { $v .= pmver('Test::More','0.88') };

Modified: trunk/libdist-zilla-plugin-git-perl/t/2-commit-build-custom.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/t/2-commit-build-custom.t?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/t/2-commit-build-custom.t (original)
+++ trunk/libdist-zilla-plugin-git-perl/t/2-commit-build-custom.t Sun Feb 20 17:35:35 2011
@@ -15,7 +15,7 @@
 use Dist::Zilla::Tester;
 use Git::Wrapper;
 use Path::Class;
-use Test::More   tests => 2;
+use Test::More   tests => 5;
 use Cwd qw(cwd);
 
 my $cwd = cwd();
@@ -37,3 +37,9 @@
 $zilla->build;
 ok( eval { $git->rev_parse('-q', '--verify', 'refs/heads/build-dev') }, 'source repo has the "build-dev" branch') or diag explain $@, $git->branch;
 is( $git->log('build-dev'), 2, 'one commit on the build-dev branch') or diag $git->branch;
+
+$zilla->release;
+ok( eval { $git->rev_parse('-q', '--verify', 'refs/heads/release') }, 'source repo has the "release" branch') or diag explain $@, $git->branch;
+my @logs = $git->log('release');
+is( scalar(@logs), 2, 'one commit on the release branch') or diag $git->branch;
+like( $logs[0]->message, qr/^Release of 1\.23\b/, 'correct release commit log message generated');

Modified: trunk/libdist-zilla-plugin-git-perl/t/commit-build-custom/dist.ini
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libdist-zilla-plugin-git-perl/t/commit-build-custom/dist.ini?rev=69156&op=diff
==============================================================================
--- trunk/libdist-zilla-plugin-git-perl/t/commit-build-custom/dist.ini (original)
+++ trunk/libdist-zilla-plugin-git-perl/t/commit-build-custom/dist.ini Sun Feb 20 17:35:35 2011
@@ -11,3 +11,5 @@
 [FakeRelease]
 [Git::CommitBuild]
 branch = build-%b
+release_branch = release
+release_message = Release of %v




More information about the Pkg-perl-cvs-commits mailing list