Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[config] Make git-related config steps do nothing unless we are in a …

…Git repo
  • Loading branch information...
commit 7240365cbf1ac9709f17f72b949d09b83b468027 1 parent 80d156e
@leto leto authored moritz committed
Showing with 4 additions and 0 deletions.
  1. +2 −0  config/auto/git_describe.pm
  2. +2 −0  config/auto/sha1.pm
View
2  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})?$/ ) {
View
2  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;
Please sign in to comment.
Something went wrong with that request. Please try again.