Skip to content

Instantly share code, notes, and snippets.

@leto
Created November 19, 2010 06:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save leto/706206 to your computer and use it in GitHub Desktop.
Save leto/706206 to your computer and use it in GitHub Desktop.
(~/git/parrot master$ )$ git diff RELEASE_2_10_0..RELEASE_2_10_1
diff --git a/config/auto/git_describe.pm b/config/auto/git_describe.pm
index e831fba..e070d44 100644
--- a/config/auto/git_describe.pm
+++ b/config/auto/git_describe.pm
@@ -31,6 +31,8 @@ sub _init {
sub runstep {
my ( $self, $conf ) = @_;
+ return 1 unless -e '.git';
+
my $describe = $Parrot::Git::Describe::current;
if ( defined($describe) and $describe !~ /^REL(EASE)?_\d+_\d+_\d+(-\d+-g[0-9A-Fa-f]{7})?$/ ) {
diff --git a/config/auto/sha1.pm b/config/auto/sha1.pm
index c05fcd3..9a716a6 100644
--- a/config/auto/sha1.pm
+++ b/config/auto/sha1.pm
@@ -30,6 +30,8 @@ sub _init {
sub runstep {
my ( $self, $conf ) = @_;
+ return 1 unless -e '.git';
+
my $sha1 = $Parrot::SHA1::current;
my $abbrev_sha1;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment