diff options
author | Wayne Davison <wayne@opencoder.net> | 2022-08-15 21:52:13 -0700 |
---|---|---|
committer | Wayne Davison <wayne@opencoder.net> | 2022-08-15 21:52:13 -0700 |
commit | 68b1ce1dc3605a8b79594ba5e8e29577ea6dc42c (patch) | |
tree | cfd20f1eac3dd2a437d506443a798dfb103dcfb6 /mkgitver | |
parent | 5a4116e553551ed314eea4bc85db8f54fd5fd03b (diff) | |
download | rsync-68b1ce1dc3605a8b79594ba5e8e29577ea6dc42c.tar.gz |
Only run git describe if .git exists in the $srcdir.
Diffstat (limited to 'mkgitver')
-rwxr-xr-x | mkgitver | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1,7 +1,10 @@ #!/bin/sh srcdir=`dirname $0` -gitver=`git describe --abbrev=8 2>/dev/null` + +if [ -e "$srcdir/.git" ]; then + gitver=`git describe --abbrev=8 2>/dev/null` +fi if [ ! -f git-version.h ]; then touch git-version.h |