From 3c7a13d81f9c2eb8566778d2fa28eaae4dd70812 Mon Sep 17 00:00:00 2001 From: Kohei Suzuki Date: Sat, 12 Dec 2015 15:28:34 +0900 Subject: [PATCH] Remove leading `:` --- libexec/rbenv-which | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libexec/rbenv-which b/libexec/rbenv-which index f4d46245..c7c0301a 100755 --- a/libexec/rbenv-which +++ b/libexec/rbenv-which @@ -23,7 +23,8 @@ remove_from_path() { path_before="$result" result="${result//:$path_to_remove:/:}" done - echo "${result%:}" + result="${result%:}" + echo "${result#:}" } RBENV_COMMAND="$1"