git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 5/5] completion: drop "stash save" completion altogether

From
D. Ben Knoble <ben.knoble@gmail.com>
Date
Oct 22, 2026, 13:14 UTC
Message-ID
<CALnO6CCUfja_AxYjbz9xpZgoibbdvy6C4utDDQk9ONhjiOYYzg@mail.gmail.com>
In-Reply-To
<atcEqHErXaGiMu4J@pks.im>
On Tue, Oct 20, 2026 at 2:05 AM Patrick Steinhardt <ps@pks.im> wrote:
Show 34 quoted lines
>
> On Mon, Oct 19, 2026 at 04:01:15PM -0400, Ben Knoble wrote:
> >
> > > Le 16 oct. 2026 à 04:01, Patrick Steinhardt <ps@pks.im> a écrit :
> > >
> > > On Mon, Oct 12, 2026 at 01:48:31PM -0400, D. Ben Knoble wrote:
> > >> It's been deprecated since fd2ebf14db (stash: mark "git stash save"
> > >> deprecated in the man page, 2017-10-22) and the previous commit removed
> > >> further documentation suggesting to use it.
> > >>
> > >> Since we recommend push instead, stop completing for "save" and remove a
> > >> special case in completion code.
> > >
> > > This is the only part I'm a bit torn on. I think it's reasonable to not
> > > autocomplete the "save" command, but if the user manually types it,
> > > should we really stop autocompleting its options altogether?
> > >
> > > Maybe the answer is "yes". After all, as you mentioned in the preceding
> > > commit, the command is deprecated since 2017 already! And after almost
> > > 10 years I think it's fair to start giving users more nudges into the
> > > direction of using "push" instead.
> > >
> > > One note though: the command _will_ be completed in the case where you
> > > have GIT_COMPLETION_SHOW_ALL set
> >
> > I should definitely mention SHOW_ALL; I’m not actually sure
> > what happens for « git stash save --<TAB> » with this patch,
> > so I’ll double-check. I actually wonder if it will complete options.
> >
> > Would that satisfy you if so ?
>
> Probably depends on the outcome of your tests, but ultimately I think
> I'd be fine with either of the options. But if we stop autocompleting we
> should definitely mention SHOW_ALL.
Here's what my testing showed (all Zsh):
- with SHOW_ALL, "git stash <tab>" lists "save" as an option; "git
stash save --<tab>" completes options
- without SHOW_ALL, "git stash <tab>" does not list "save"; "git stash
sa<tab>" does not complete "save"; "git stash save --<tab>" completes
options
I'll update the commit locally to reflect this. Thoughts?
-- 
D. Ben Knoble
Previous: Patrick SteinhardtNext: Patrick Steinhardt
Message 15 of 28 in “stash completion miscellany”
  1. 0/5 stash completion miscellanyD. Ben Knoble, Oct 12, 2026
  2. 1/5 completion: simplify stash subcommand completionD. Ben Knoble, Oct 12, 2026
  3. Patrick SteinhardtOct 16, 2026
  4. Ben KnobleOct 19, 2026
  5. 2/5 completion: extract common stash listing codeD. Ben Knoble, Oct 12, 2026
  6. 3/5 completion: fix Zsh handling of stash namesD. Ben Knoble, Oct 12, 2026
  7. Patrick SteinhardtOct 16, 2026
  8. Ben KnobleOct 19, 2026
  9. 4/5 doc: drop usage mentions of "git stash save"D. Ben Knoble, Oct 12, 2026
  10. Patrick SteinhardtOct 16, 2026
  11. 5/5 completion: drop "stash save" completion altogetherD. Ben Knoble, Oct 12, 2026
  12. Patrick SteinhardtOct 16, 2026
  13. Ben KnobleOct 19, 2026
  14. Patrick SteinhardtOct 20, 2026
  15. D. Ben KnobleOct 22, 2026
  16. Patrick SteinhardtOct 23, 2026
  17. 0/5 stash completion miscellanyD. Ben Knoble, Oct 23, 2026
  18. 1/5 completion: simplify stash subcommand completionD. Ben Knoble, Oct 23, 2026
  19. 2/5 Completion: extract common stash listing codeD. Ben Knoble, Oct 23, 2026
  20. Junio C HamanoOct 23, 2026
  21. 3/5 completion: fix Zsh handling of stash namesD. Ben Knoble, Oct 23, 2026
  22. 4/5 doc: drop usage mentions of "git stash save"D. Ben Knoble, Oct 23, 2026
  23. 5/5 completion: drop "stash save" completion altogetherD. Ben Knoble, Oct 23, 2026
  24. Junio C HamanoOct 23, 2026
  25. Ben KnobleOct 23, 2026
  26. Kristoffer HaugsbakkOct 23, 2026
  27. Patrick SteinhardtOct 26, 2026
  28. Junio C HamanoOct 26, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.