git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* Bash completion for git aliases containing nested subcommands
@ 2022-10-03 11:45 Tim Jaacks
  2022-10-03 14:24 ` SZEDER Gábor
  0 siblings, 1 reply; 7+ messages in thread
From: Tim Jaacks @ 2022-10-03 11:45 UTC (permalink / raw)
  To: git

Hello everyone,

I have set up the following alias in my .gitconfig file:

[alias]
     ss = stash show

Unfortunately bash completion does not work correctly on this alias. 
When I type "git ss <TAB>", I get:

$ git ss <TAB>
apply clear drop pop show
branch create list push

Which is obviously the completion for "git stash" instead of "git stash 
show".

With the original command I get the list of available stashes:

$ git stash show <TAB>
stash@{0} stash@{1}

Is there a way to get the completion on the alias behave like on the 
original command?

I am on Ubuntu 20.04 and using the distro's default git completions.

Kind regards,
Tim


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2022-10-05 10:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-03 11:45 Bash completion for git aliases containing nested subcommands Tim Jaacks
2022-10-03 14:24 ` SZEDER Gábor
     [not found]   ` <1839e62f930.285a.8a94aeaa49923dfb9a7d55a303990d0a@posteo.de>
2022-10-03 15:11     ` Tim Jaacks
2022-10-03 15:43     ` SZEDER Gábor
2022-10-03 22:24   ` Jeff King
2022-10-04 11:21     ` Tim Jaacks
2022-10-05 10:05     ` SZEDER Gábor

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).