mirror of
https://github.com/git/git.git
synced 2024-10-28 12:59:41 +01:00
contrib/completion: complete options that take refs for format-patch
The completion for format-patch currently suggests --base=, --interdiff= and --range-diff= as options. However, with these `=` forms of the options, there is no space and we'd enter the `--*` case which means we don't call the __git_complete_revlist() at the end. Teach _git_format_patch() to complete refs in the case of --base=, --interdiff= and --range-diff=. Signed-off-by: Denton Liu <liu.denton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
54e85e7af1
commit
93ab00bd85
1 changed files with 4 additions and 0 deletions
|
@ -1784,6 +1784,10 @@ _git_format_patch ()
|
||||||
" "" "${cur##--thread=}"
|
" "" "${cur##--thread=}"
|
||||||
return
|
return
|
||||||
;;
|
;;
|
||||||
|
--base=*|--interdiff=*|--range-diff=*)
|
||||||
|
__git_complete_refs --cur="${cur#--*=}"
|
||||||
|
return
|
||||||
|
;;
|
||||||
--*)
|
--*)
|
||||||
__gitcomp_builtin format-patch "$__git_format_patch_extra_options"
|
__gitcomp_builtin format-patch "$__git_format_patch_extra_options"
|
||||||
return
|
return
|
||||||
|
|
Loading…
Reference in a new issue