From db9ca5976379bb28ab261180e41ceffe7debee4c Mon Sep 17 00:00:00 2001 From: John Ralls Date: Tue, 17 May 2011 18:24:10 +0000 Subject: [PATCH] Force /bin/echo in git section Apple's version of bash version 3, when called as /bin/sh, uses an internal echo command which doesn't handle the "-n" argument and contaminates the git version string. /bin/echo correctly handles the -n argument. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@20654 57a11ea4-9604-0410-9ed3-97b8803252fd --- util/gnc-svnversion | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/util/gnc-svnversion b/util/gnc-svnversion index cb9c926895..4b0363f32a 100755 --- a/util/gnc-svnversion +++ b/util/gnc-svnversion @@ -69,12 +69,12 @@ if test -d "${real_gitdir}" then githead=`git --git-dir "${real_gitdir}" log -1 --pretty=format:"%h" HEAD 2>/dev/null` # short hash only if test $? = 0 ; then - echo -n $githead + /bin/echo -n $githead # Add a "+" to the hash if there deleted or modified files (not excluded by .gitignore and friends) # "Ignores" untracked files - # [ $(git --git-dir "${real_gitdir}" ls-files -dkm 2>/dev/null | wc -l) -gt 0 ] && echo -n "+" + # [ $(git --git-dir "${real_gitdir}" ls-files -dkm 2>/dev/null | wc -l) -gt 0 ] && /bin/echo -n "+" # Includes untracked files - [ $(git --git-dir "${real_gitdir}" ls-files -dkmo --exclude-standard 2>/dev/null | wc -l) -gt 0 ] && echo -n "+" + [ $(git --git-dir "${real_gitdir}" ls-files -dkmo --exclude-standard 2>/dev/null | wc -l) -gt 0 ] && /bin/echo -n "+" echo exit 0 else