[PATCH 2/3] completion: stop completing 'save' as stash subcommand

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The 'save' subcommand in git stash has been deprecated in
fd2ebf14db ("stash: mark "git stash save" deprecated in the man page",
2017-10-22).  It is however still completed by the git bash
completion.

Stop completing the 'save' subcommand as a further step in the
deprecation process.  As the only use of the bash completion is
interactive, this wouldn't break any scripts, but may give users a
hint that the command is deprecated.

Signed-off-by: Thomas Gummerer <t.gummerer@xxxxxxxxx>
---
 contrib/completion/git-completion.bash | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index 39c123926c..452c3d4490 100644
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -2774,7 +2774,7 @@ _git_show_branch ()
 _git_stash ()
 {
 	local default_opts='--all --keep-index --no-keep-index --quiet --patch --include-untracked'
-	local subcommands='push save list show apply clear drop pop create branch'
+	local subcommands='push list show apply clear drop pop create branch'
 	local subcommand="$(__git_find_on_cmdline "$subcommands")"
 	if [ -z "$subcommand" ]; then
 		case "$cur" in
@@ -2792,9 +2792,6 @@ _git_stash ()
 		push,--*)
 			__gitcomp "$default_opts --message"
 			;;
-		save,--*)
-			__gitcomp "$default_opts"
-			;;
 		apply,--*|pop,--*)
 			__gitcomp "--index --quiet"
 			;;
-- 
2.17.0.252.gfe0a9eaf31




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux