completion: simplify _git_notes
This also adds completion for 'git notes remove' and 'git notes edit'. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
b475e442e8
commit
4ea2c974a0
@ -1836,19 +1836,11 @@ _git_notes ()
|
|||||||
add,--reedit-message=*|append,--reedit-message=*)
|
add,--reedit-message=*|append,--reedit-message=*)
|
||||||
__git_complete_refs --cur="${cur#*=}"
|
__git_complete_refs --cur="${cur#*=}"
|
||||||
;;
|
;;
|
||||||
add,--*)
|
*,--*)
|
||||||
__gitcomp_builtin notes_add
|
__gitcomp_builtin notes_$subcommand
|
||||||
;;
|
|
||||||
append,--*)
|
|
||||||
__gitcomp_builtin notes_append
|
|
||||||
;;
|
|
||||||
copy,--*)
|
|
||||||
__gitcomp_builtin notes_copy
|
|
||||||
;;
|
|
||||||
prune,--*)
|
|
||||||
__gitcomp_builtin notes_prune
|
|
||||||
;;
|
;;
|
||||||
prune,*)
|
prune,*)
|
||||||
|
# this command does not take a ref, do not complete it
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
case "$prev" in
|
case "$prev" in
|
||||||
|
Loading…
Reference in New Issue
Block a user