Skip to content

Commit 25b3e4f

Browse files
committed
Merge branch 'dk/version-gen-gitdir' into maint
* dk/version-gen-gitdir: GIT-VERSION-GEN: support non-standard $GIT_DIR path
2 parents b6538a0 + 05a9506 commit 25b3e4f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

GIT-VERSION-GEN

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ LF='
1111
if test -f version
1212
then
1313
VN=$(cat version) || VN="$DEF_VER"
14-
elif test -d .git -o -f .git &&
14+
elif test -d ${GIT_DIR:-.git} -o -f .git &&
1515
VN=$(git describe --match "v[0-9]*" --abbrev=7 HEAD 2>/dev/null) &&
1616
case "$VN" in
1717
*$LF*) (exit 1) ;;

0 commit comments

Comments
 (0)