From a237e7f860bb4705823077e90b2ecc599746e46c Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 20 Jan 2014 23:21:48 +0100 Subject: CommandLine: show the current git tag and commit id --- configure.ac | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 71fdb0e1d..52db236ba 100644 --- a/configure.ac +++ b/configure.ac @@ -15,6 +15,10 @@ AC_CONFIG_MACRO_DIR([m4]) AC_DEFINE(PROTOCOL_VERSION, "0.19.0", [The MPD protocol version]) +GIT_COMMIT=`GIT_DIR="$srcdir/.git" git describe --dirty --always 2>/dev/null` +if test x$GIT_COMMIT != x; then + AC_DEFINE_UNQUOTED(GIT_COMMIT, ["$GIT_COMMIT"], [The current git commit]) +fi dnl --------------------------------------------------------------------------- dnl Programs -- cgit v1.2.3