diff --git a/plugins/apps/internal-functions b/plugins/apps/internal-functions index fb2def2d4..5f92c2439 100755 --- a/plugins/apps/internal-functions +++ b/plugins/apps/internal-functions @@ -55,7 +55,7 @@ cmd-apps-report-single() { if [[ "$use_echo" ]]; then echo "not deployed" else - dokku_log_exit "not deployed" + dokku_log_exit_quiet "not deployed" fi fi else diff --git a/plugins/apps/subcommands/exists b/plugins/apps/subcommands/exists index 608a6d9c0..b5cbb4108 100755 --- a/plugins/apps/subcommands/exists +++ b/plugins/apps/subcommands/exists @@ -12,7 +12,7 @@ apps_exists_cmd() { if ! apps_exists "$APP"; then dokku_log_fail "App does not exist" fi - dokku_log_info1 "App already exists" + dokku_log_info1 "App exists" } apps_exists_cmd "$@" diff --git a/plugins/common/functions b/plugins/common/functions index 2cb56ca93..592cc2e9c 100755 --- a/plugins/common/functions +++ b/plugins/common/functions @@ -130,9 +130,7 @@ dokku_log_exit_quiet() { dokku_log_exit() { declare desc="log exit formatter" - if [[ -z "$DOKKU_QUIET_OUTPUT" ]]; then - echo "$@" 1>&2 - fi + echo "$@" 1>&2 exit 0 } @@ -150,6 +148,11 @@ dokku_log_fail() { exit 1 } +dokku_log_stderr() { + declare desc="log stderr formatter" + echo "$@" 1>&2 +} + dokku_log_event() { declare desc="log dokku events" logger -t dokku-event -i -- "$@" diff --git a/plugins/common/log.go b/plugins/common/log.go index 68f130ba0..e60e912c4 100644 --- a/plugins/common/log.go +++ b/plugins/common/log.go @@ -54,3 +54,8 @@ func LogVerboseQuiet(text string) { func LogWarn(text string) { fmt.Fprintln(os.Stderr, fmt.Sprintf(" ! %s", text)) } + +// LogStderr is the stderr log formatter +func LogStderr(text string) { + fmt.Fprintln(os.Stderr, text) +}