Since we can't automatically extract diff options for completion yet, difftool will take all options from $__git_diff_common_options. This brings _a lot_ more completable options to difftool. --ignore-submodules is added to $__git_diff_common_options to avoid regression in difftool. But it's a good thing anyway even for other diff commands. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx> --- contrib/completion/git-completion.bash | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash index 7a98f01067..7763f88347 100644 --- a/contrib/completion/git-completion.bash +++ b/contrib/completion/git-completion.bash @@ -1394,7 +1394,7 @@ __git_diff_common_options="--stat --numstat --shortstat --summary --dirstat --dirstat= --dirstat-by-file --dirstat-by-file= --cumulative --diff-algorithm= - --submodule --submodule= + --submodule --submodule= --ignore-submodules " _git_diff () @@ -1435,11 +1435,11 @@ _git_difftool () return ;; --*) - __gitcomp "--cached --staged --pickaxe-all --pickaxe-regex - --base --ours --theirs - --no-renames --diff-filter= --find-copies-harder - --relative --ignore-submodules - --tool=" + __gitcomp_builtin difftool "$__git_diff_common_options + --base --cached --ours --theirs + --pickaxe-all --pickaxe-regex + --relative --staged + " return ;; esac -- 2.16.1.207.gedba492059