blob: 204ffec43dc5b5530237ec06596a3da5c8c1d6b0 (
plain) (
tree)
|
|
#!/bin/sh
if head=`git rev-parse --verify HEAD 2>/dev/null`; then
git update-index --refresh --unmerged > /dev/null
printf "#define ANTISPAM_GIT_VERSION \"git %.8s" "$head"
if git diff-index --name-only HEAD | read dummy ; then
printf ", dirty"
fi
echo '"'
else
echo '#define ANTISPAM_GIT_VERSION "unknown"'
fi
|