Raise a warning when working with an outdated version of git and attempt to work around it's limitations.

Closes #2536.
master
dak180 2011-03-16 10:47:53 -04:00
parent 564c5a4ee8
commit dde0d33f00
1 changed files with 4 additions and 0 deletions

View File

@ -17,6 +17,10 @@ function gitRepo {
# Enumeration of changesets
VCS_NUM="$(git rev-list --count HEAD)"
if [ -z "${VCS_NUM}" ]; then
echo "warning: Your version of git is outdated and cause errors when compiling, please upgrade."
VCS_NUM="$(git rev-list HEAD | wc -l)"
fi
# The full revision hash
VCS_FULL_HASH="$(git rev-parse HEAD)"