From eebd69a0513107fbeb6471c45434b493fa5e12aa Mon Sep 17 00:00:00 2001 From: diego Date: Fri, 23 Jun 2006 15:12:56 +0000 Subject: Produce correct version string even when not run in a Subversion working copy. ported from FFmpeg git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@18794 b3059339-0415-0410-9bf9-f77b7e298cf2 --- version.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'version.sh') diff --git a/version.sh b/version.sh index 6a77cc415d..74400c2f94 100755 --- a/version.sh +++ b/version.sh @@ -2,7 +2,9 @@ test "$1" && extra="-$1" -svn_revision=`svn info | grep Revision | cut -d' ' -f2 || echo UNKNOWN` +svn_revision=`svn info 2> /dev/null | grep Revision | cut -d' ' -f2` +test $svn_revision || svn_revision=UNKNOWN + NEW_REVISION="#define VERSION \"dev-SVN-r${svn_revision}${extra}\"" OLD_REVISION=`cat version.h 2> /dev/null` -- cgit v1.2.3