From 4668a2e2ed8c8dfcd935247a4e5dcf26a35f63ac Mon Sep 17 00:00:00 2001 From: Sam Stephenson Date: Wed, 3 Aug 2011 00:06:23 -0500 Subject: [PATCH] rbenv-whence requires a command argument --- libexec/rbenv-whence | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libexec/rbenv-whence b/libexec/rbenv-whence index 30613eed..b6809a56 100755 --- a/libexec/rbenv-whence +++ b/libexec/rbenv-whence @@ -18,5 +18,10 @@ whence() { } RBENV_COMMAND="$1" +if [ -z "$RBENV_COMMAND" ]; then + echo "usage: rbenv whence [--path] COMMAND" >&2 + exit 1 +fi + result="$(whence "$RBENV_COMMAND")" [ -n "$result" ] && echo "$result"