[Xfce4-commits] <xfconf:xfce-4.6> Make build suitable for GIT.

Nick Schermer noreply at xfce.org
Thu May 13 21:18:04 CEST 2010


Updating branch refs/heads/xfce-4.6
         to 7f32d31585110808bc4dbeed06c025e5a7ca1acf (commit)
       from 3cf1631aedc9638efc60b3dcb233f776676e5ff5 (commit)

commit 7f32d31585110808bc4dbeed06c025e5a7ca1acf
Author: Nick Schermer <nick at xfce.org>
Date:   Thu May 13 20:46:44 2010 +0200

    Make build suitable for GIT.

 autogen.sh |   21 ++++++++++++---------
 1 files changed, 12 insertions(+), 9 deletions(-)

diff --git a/autogen.sh b/autogen.sh
index 170897e..2ce96ce 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -34,15 +34,18 @@ echo >>configure.ac
 
 # substitute revision and linguas
 linguas=$(sed -e '/^#/d' po/LINGUAS)
-if [ -d .git/svn ]; then
-    revision=$(git svn find-rev trunk 2>/dev/null ||
-               git svn find-rev origin/trunk 2>/dev/null ||
-               git svn find-rev HEAD 2>/dev/null ||
-               git svn find-rev master 2>/dev/null)
-elif [ -d .svn ]; then
-    revision=$(LC_ALL=C svn info $0 | awk '/^Revision: / {printf "%05d\n", $2}')
-else
-    revision=UNKNOWN
+if test -d .git/svn; then
+    revision=`git svn find-rev trunk 2>/dev/null ||
+              git svn find-rev origin/trunk 2>/dev/null ||
+              git svn find-rev HEAD 2>/dev/null ||
+              git svn find-rev master 2>/dev/null`
+elif test -d .git; then
+    revision=`git rev-parse --short HEAD`
+elif test -d .svn; then
+    revision=`LC_ALL=C svn info $0 | $AWK '/^Revision: / {printf "%05d\n", $2}'`
+fi
+if test "x$revision" = "x"; then
+    revision="UNKNOWN"
 fi
 sed -e "s/@LINGUAS@/${linguas}/g" \
     -e "s/@REVISION@/${revision}/g" \



More information about the Xfce4-commits mailing list