forked from mia/Aegisub
Add support for getting the revision number from git
Originally committed to SVN as r6174.
This commit is contained in:
parent
f02ccdd331
commit
b7cd695cd6
1 changed files with 3 additions and 0 deletions
|
@ -161,6 +161,9 @@ AS_IF([test -d "$srcdir/.svn"], [
|
||||||
], [test -f "$srcdir/svn_revision"], [
|
], [test -f "$srcdir/svn_revision"], [
|
||||||
SVN_REVISION=`cat $srcdir/svn_revision`
|
SVN_REVISION=`cat $srcdir/svn_revision`
|
||||||
AC_MSG_RESULT([$SVN_REVISION from "$srcdir/svn_revision"])
|
AC_MSG_RESULT([$SVN_REVISION from "$srcdir/svn_revision"])
|
||||||
|
], [test -d "$srcdir/../.git"], [
|
||||||
|
SVN_REVISION=[`git log | grep git-svn-id -m 1 | sed 's/.*@\([0-9]\+\) .*/\1/'`]
|
||||||
|
AC_MSG_RESULT([$SVN_REVISION from git])
|
||||||
], [
|
], [
|
||||||
AC_MSG_RESULT([not found])
|
AC_MSG_RESULT([not found])
|
||||||
AC_MSG_FAILURE([unable to get SVN Revision from $srcdir/svn_revision or 'svnversion $srcdir'])
|
AC_MSG_FAILURE([unable to get SVN Revision from $srcdir/svn_revision or 'svnversion $srcdir'])
|
||||||
|
|
Loading…
Reference in a new issue