completion: teach replace to complete options

Git-replace needs to complete references and its own options. In addition to the existing references completions, do also complete the options --edit --graft --format= --list --delete. 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 188fba1172964da1d0169535e859381c3f2b1191
1 file changed +6
contrib/completion/git-completion.bash
+6
@@ -2408,6 +2408,12 @@ _git_remote ()
2408
2409 _git_replace ()
2410 {
2411 + case "$cur" in
2412 + --*)
2413 + __gitcomp "--edit --graft --format= --list --delete"
2414 + return
2415 + ;;
2416 + esac
2417 __gitcomp_nl "$(__git_refs)"
2418 }
2419