Change in openbsc[master]: git-version-gen: Don't check for .git directory

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Fri Jul 27 07:37:34 UTC 2018


Harald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/10144 )

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

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: Ibc8c0d8e74bb03bfe87d6f8b9ef6e74c0c889d0f
---
M openbsc/git-version-gen
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  Neels Hofmeyr: Looks good to me, approved



diff --git a/openbsc/git-version-gen b/openbsc/git-version-gen
index f2ad4a7..42cf3d2 100755
--- a/openbsc/git-version-gen
+++ b/openbsc/git-version-gen
@@ -92,8 +92,8 @@
 if test -n "$v"
 then
     : # use $v
-elif test -d ./../.git \
-    && v=`git describe --abbrev=4 --match='v*' HEAD 2>/dev/null \
+elif
+       v=`git describe --abbrev=4 --match='v*' HEAD 2>/dev/null \
 	  || git describe --abbrev=4 HEAD 2>/dev/null` \
     && case $v in
 	 [0-9]*) ;;

-- 
To view, visit https://gerrit.osmocom.org/10144
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ibc8c0d8e74bb03bfe87d6f8b9ef6e74c0c889d0f
Gerrit-Change-Number: 10144
Gerrit-PatchSet: 1
Gerrit-Owner: daniel <dwillmann at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20180727/10d8b113/attachment.htm>


More information about the gerrit-log mailing list