Avoid assuming rbenv original project layout

Someone packaging rbenv might choose to place the `bin` and `libexec` directories separately.
This commit is contained in:
Mislav Marohnić 2022-10-07 16:38:28 +02:00
parent 6b1cc34610
commit d97713d1b5
No known key found for this signature in database

View file

@ -45,8 +45,7 @@ rbenv_path() {
echo "$PWD/${found#./}"
else
# Assume rbenv isn't in PATH.
local here="${BASH_SOURCE%/*}"
echo "${here%/*}/bin/rbenv"
echo "${BASH_SOURCE%/*}/rbenv"
fi
}