Skip to content
Snippets Groups Projects
Commit fb3a0cab authored by Junio C Hamano's avatar Junio C Hamano
Browse files

Merge branch 'fg/completion-external'

The command line completion mechanism (in contrib/) learned to load
custom completion file for "git $command" where $command is a
custom "git-$command" that the end user has on the $PATH when using
newer version of bash.

* fg/completion-external:
  completion: load completion file for external subcommand
parents d7e96110 085e2ee0
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -3073,10 +3073,17 @@ __git_support_parseopt_helper () {
__git_complete_command () {
local command="$1"
local completion_func="_git_${command//-/_}"
if declare -f $completion_func >/dev/null 2>/dev/null; then
if ! declare -f $completion_func >/dev/null 2>/dev/null &&
declare -f _completion_loader >/dev/null 2>/dev/null
then
_completion_loader "git-$command"
fi
if declare -f $completion_func >/dev/null 2>/dev/null
then
$completion_func
return 0
elif __git_support_parseopt_helper "$command"; then
elif __git_support_parseopt_helper "$command"
then
__git_complete_common "$command"
return 0
else
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment