From c7ba6209df4c09c92d4c81e3f89c02ac11cb7508 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Sat, 13 Jun 2009 14:30:05 +0200 Subject: [PATCH] version.sh: fix bashisms Signed-off-by: Sergei Trofimovich --- maint/version.sh | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/maint/version.sh b/maint/version.sh index 933c14e9a..944a38e9d 100755 --- a/maint/version.sh +++ b/maint/version.sh @@ -21,13 +21,11 @@ src_top_dir= VERSION_FILE=${src_top_dir}/version.h -pushd ${src_top_dir} &>/dev/null -git_head=$(git rev-parse --verify HEAD 2>/dev/null) +git_head=$(git --git-dir "${src_top_dir}" rev-parse --verify HEAD 2>/dev/null) [ -z "${git_head}" ] && exit -new_version="$(git describe 2>/dev/null)" +new_version="$(git --git-dir "${src_top_dir}" describe 2>/dev/null)" [ -z "${new_version}" ] && exit -popd &>/dev/null saved_version=