]> git.ipfire.org Git - thirdparty/git.git/commitdiff
completion: use __gitcomp_builtin in _git_mv
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>
Fri, 9 Feb 2018 11:02:06 +0000 (18:02 +0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 9 Feb 2018 18:24:52 +0000 (10:24 -0800)
The new completable option is --verbose.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/mv.c
contrib/completion/git-completion.bash

index b88023a733ff263f13b12bb0e618f15da0f74a11..e3e308d282f45ac0e8e68be6732043f0cd039d96 100644 (file)
@@ -122,7 +122,8 @@ int cmd_mv(int argc, const char **argv, const char *prefix)
        struct option builtin_mv_options[] = {
                OPT__VERBOSE(&verbose, N_("be verbose")),
                OPT__DRY_RUN(&show_only, N_("dry run")),
-               OPT__FORCE(&force, N_("force move/rename even if target exists"), 0),
+               OPT__FORCE(&force, N_("force move/rename even if target exists"),
+                          PARSE_OPT_NOCOMPLETE),
                OPT_BOOL('k', NULL, &ignore_errors, N_("skip move/rename errors")),
                OPT_END(),
        };
index b192a5c0a13c3a05c24455ef9c7d51032df3090a..bbf8623e3ad8dd47eae7d7925808cfd5571b61a0 100644 (file)
@@ -1809,7 +1809,7 @@ _git_mv ()
 {
        case "$cur" in
        --*)
-               __gitcomp "--dry-run"
+               __gitcomp_builtin mv
                return
                ;;
        esac