mirror of
https://github.com/rbenv/rbenv.git
synced 2024-12-29 13:15:42 +01:00
handle --help for subcommands
If subcommand is provided (and exists) and its first arg is -h/--help, go ahead and intercept the call; redirecting to rbenv-help <subcommand> This means subcommands and plugins need not handle --help flag themselves
This commit is contained in:
parent
06e4f1b682
commit
2c4dd63f77
1 changed files with 5 additions and 1 deletions
|
@ -111,6 +111,10 @@ case "$command" in
|
|||
fi
|
||||
|
||||
shift 1
|
||||
if [ "$1" = --help ]; then
|
||||
exec rbenv-help "$command"
|
||||
else
|
||||
exec "$command_path" "$@"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
|
Loading…
Reference in a new issue