1
0
mirror of https://github.com/pyenv/pyenv.git synced 2025-11-15 06:43:53 -05:00

improve detection of completion support for commands

Enable JavasCript, Lua and Erlang scripts to provide completions
This commit is contained in:
Alisdair Sullivan
2013-03-31 21:01:07 -07:00
committed by Mislav Marohnić
parent 4d96d0a6c6
commit 497911d6c0

View File

@@ -11,7 +11,7 @@ if [ -z "$COMMAND" ]; then
fi
COMMAND_PATH="$(command -v "rbenv-$COMMAND" || command -v "rbenv-sh-$COMMAND")"
if grep -i "^# provide rbenv completions" "$COMMAND_PATH" >/dev/null; then
if grep -i "^\([#%]\|--\|//\) provide rbenv completions" "$COMMAND_PATH" >/dev/null; then
shift
exec "$COMMAND_PATH" --complete "$@"
fi