use git describe for naming version in pure git clones
authorRamiro Polla <ramiro@lisha.ufsc.br>
Sun, 16 Jan 2011 18:34:09 +0000 (18:34 +0000)
committerJanne Grunau <janne-ffmpeg@jannau.net>
Sun, 16 Jan 2011 18:34:09 +0000 (18:34 +0000)
Patch by: Ramiro Polla <ramiro <DOT> polla  gmail <DOT> com>

Originally committed as revision 26394 to svn://svn.ffmpeg.org/ffmpeg/trunk

version.sh

index f8510ea..f45c60d 100755 (executable)
@@ -18,7 +18,7 @@ fi
 
 # check for git short hash
 if ! test $revision; then
-    revision=$(cd "$1" && git log -1 --pretty=format:%h 2> /dev/null)
+    revision=$(cd "$1" && git describe --always 2> /dev/null)
     test $revision && revision=git-$revision
 fi