lib/Moose/Meta/Attribute/Native/Trait.pm: factor out some of the namespace resolution...
[gitmo/Moose.git] / inc / GitUpToDate.pm
index 35020e7..2f6c9ea 100644 (file)
@@ -1,7 +1,7 @@
 package inc::GitUpToDate;
 use Moose;
 
-with 'Dist::Zilla::Role::BeforeRelease';
+with 'Dist::Zilla::Role::BeforeBuild';
 
 sub git {
     if (wantarray) {
@@ -14,9 +14,11 @@ sub git {
     }
 }
 
-sub before_release {
+sub before_build {
     my $self = shift;
 
+    return unless $ENV{DZIL_RELEASING};
+
     my $branch = git "symbolic-ref HEAD";
     die "Could not get the current branch"
         unless $branch;