changed_templates: use $GIT_CMD instead of git everywhere
This commit is contained in:
parent
b739f8c23a
commit
2380f8cb1a
|
@ -8,13 +8,13 @@ elif command -v git >/dev/null 2>&1; then
|
||||||
GIT_CMD=$(command -v git)
|
GIT_CMD=$(command -v git)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
tip="$(git rev-list -1 --parents HEAD)"
|
tip="$($GIT_CMD rev-list -1 --parents HEAD)"
|
||||||
case "$tip" in
|
case "$tip" in
|
||||||
*" "*" "*) tip="${tip##* }" ;;
|
*" "*" "*) tip="${tip##* }" ;;
|
||||||
*) tip="${tip%% *}" ;;
|
*) tip="${tip%% *}" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
base="$(git merge-base FETCH_HEAD "$tip")" || {
|
base="$($GIT_CMD merge-base FETCH_HEAD "$tip")" || {
|
||||||
echo "Your branches is based on too old copy."
|
echo "Your branches is based on too old copy."
|
||||||
echo "Please rebase to newest copy."
|
echo "Please rebase to newest copy."
|
||||||
exit 1
|
exit 1
|
||||||
|
|
Loading…
Reference in New Issue