git-version-gen: Don't check for .git directory

This check is not in all our repos that use git-version-gen. Indeed it
seems to be a leftover of openbsc where I think it wanted to ensure
being called in the openbsc subfolder or something? libosmocore e.g.
doesn't have it.

In any case .git being a directory is not always true (if using git
worktree) so remove this check.

Change-Id: I83b84099c34d593a8a384f001a8131c2a8085606
Daniel Willmann 2018-07-24 17:51:58 +02:00 committed by Daniel Willmann
parent 35a382968c
commit 9cd5233609
1 changed files with 2 additions and 2 deletions

View File

@ -92,8 +92,8 @@ fi
if test -n "$v"
: # use $v
elif test -d ./.git \
&& v=`git describe --abbrev=4 --match='v*' HEAD 2>/dev/null \
v=`git describe --abbrev=4 --match='v*' HEAD 2>/dev/null \
|| git describe --abbrev=4 HEAD 2>/dev/null` \
&& case $v in
[0-9]*) ;;