completion: factor out untracked file modes into a variable
Signed-off-by: Thomas Braun <thomas.braun@virtuell-zuhause.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Thomas Braun committed
Jun 10, 2016 at 12:12 UTC
21d2a9e3cce6167a3cf69303ad5b35ec819a763b
1 file changed
+3
-1
contrib/completion/git-completion.bash
+3
-1
@@ -1098,6 +1098,8 @@ _git_clone ()
1098
esac
1099
}
1100
1101
+__git_untracked_file_modes="all no normal"
1102
+
1103
_git_commit ()
1104
{
1105
case "$prev" in
@@ -1119,7 +1121,7 @@ _git_commit ()
1121
return
1122
;;
1123
--untracked-files=*)
1122
- __gitcomp "all no normal" "" "${cur##--untracked-files=}"
1124
+ __gitcomp "$__git_untracked_file_modes" "" "${cur##--untracked-files=}"
1125
return
1126
;;
1127
--*)