From 7860ad5268753f005c7ecc121d186fd16370f8d9 Mon Sep 17 00:00:00 2001 From: "Yamashita, Yuu" Date: Fri, 1 Jul 2016 00:08:19 +0000 Subject: [PATCH] Help message should not be written to stdout for `sh-` commands (yyuu/pyenv#650) --- libexec/rbenv | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libexec/rbenv b/libexec/rbenv index d77df669..b0b0e91b 100755 --- a/libexec/rbenv +++ b/libexec/rbenv @@ -109,7 +109,11 @@ case "$command" in shift 1 if [ "$1" = --help ]; then - exec rbenv-help "$command" + if [[ "$command" == "sh-"* ]]; then + exec rbenv-help "$command" 1>&2 + else + exec rbenv-help "$command" + fi else exec "$command_path" "$@" fi