completion: add subcommand completion for rerere

Managing recorded resolutions requires command-line usage of git-rerere.
Added subcommand completion for rerere and path completion for its
subcommand forget.

Signed-off-by: Cornelius Weig <cornelius.weig@tngtech.com>
Reviewed-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Cornelius Weig 2017-02-03 12:01:54 +01:00 committed by Junio C Hamano
parent 65d5a1e0a5
commit e24a256b59

View File

@ -2401,6 +2401,17 @@ _git_replace ()
__gitcomp_nl "$(__git_refs)"
}
_git_rerere ()
{
local subcommands="clear forget diff remaining status gc"
local subcommand="$(__git_find_on_cmdline "$subcommands")"
if test -z "$subcommand"
then
__gitcomp "$subcommands"
return
fi
}
_git_reset ()
{
__git_has_doubledash && return