fix: ensure git check-ref-format runs quietly

This commit is contained in:
Jose Diaz-Gonzalez
2017-04-10 17:12:32 -06:00
parent b21f4b6470
commit 45518fce6c

View File

@@ -107,7 +107,7 @@ git_hook_cmd() {
local APP="$2"
local DOKKU_DEPLOY_BRANCH="$(git_deploy_branch "$APP")"
if ! git check-ref-format --branch "$DOKKU_DEPLOY_BRANCH" 2> /dev/null; then
if ! git check-ref-format --branch "$DOKKU_DEPLOY_BRANCH" > /dev/null 2>&1; then
echo $'\e[1G\e[K'"-----> WARNING: Invalid branch name '$DOKKU_DEPLOY_BRANCH' specified via DOKKU_DEPLOY_BRANCH."
echo $'\e[1G\e[K'"-----> For more details, please see the man page for 'git-check-ref-format.'"
return