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>
Cornelius Weig committed
Feb 3, 2017 at 12:01 UTC
e24a256b5946f933d19d68ec071d80990bffcebd
1 file changed
+11
contrib/completion/git-completion.bash
+11
@@ -2401,6 +2401,17 @@ _git_replace ()
2401
__gitcomp_nl "$(__git_refs)"
2402
}
2403
2404
+_git_rerere ()
2405
+{
2406
+ local subcommands="clear forget diff remaining status gc"
2407
+ local subcommand="$(__git_find_on_cmdline "$subcommands")"
2408
+ if test -z "$subcommand"
2409
+ then
2410
+ __gitcomp "$subcommands"
2411
+ return
2412
+ fi
2413
+}
2414
+
2415
_git_reset ()
2416
{
2417
__git_has_doubledash && return