Subject: Re: [PATCH v10 0/4] checkout: 'autostash' for branch switching

From: Junio C Hamano <[email-masked]>
Date: Mon, 13 Apr 2026 15:45:17 -0700

"Harald Nordgren via GitGitGadget" <[email-masked]> writes:

> Harald Nordgren (4):
>   stash: add --label-ours, --label-theirs, --label-base for apply
>   sequencer: allow create_autostash to run silently
>   sequencer: teach autostash apply to take optional conflict marker
>     labels
>   checkout: -m (--merge) uses autostash when switching branches

I have been trying this in my real workflow and noticed only one
minor annoyance, which is that the stash entry only says
"autostash", which is not very illuminating.

Because I almost always have either 'master' or 'next' checked out,
when I start outlining a "how about this" kind of change, they are
made on top of these branches, but when I say "checkout -m topic"
after that, I _know_ that the rough draft change that becomes a
stash entry is meant to be part of the "topic", either to extend it
or refine it.  Because the code that creates the stash entry knows
that we were in the process of moving to 'topic', it would be nice
to see the name of the branch we are moving to (i.e., 'topic') on
the title, e.g., "autostash while switching to 'topic'".

Other than that, it is a very pleasant usability enhancement.

Thanks.