git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
* Can not list stash (git version 2.30.0)
@ 2021-04-07 17:49 Eugen Konkov
  2021-04-07 19:48 ` Jeff King
  0 siblings, 1 reply; 2+ messages in thread
From: Eugen Konkov @ 2021-04-07 17:49 UTC (permalink / raw)
  To: Git Mailing List

Hello Git,

I am in progress of rebasing

~/e/Auth/Mojolicious/Plugin $ git rebase aa3376
Created autostash: 4018bc7
hint: Waiting for your editor to close the file...


while I am in editor I switched to different console to view created autostash:

~/e/Auth $ git stash list

and see nothing

but can view stash by its id:
~/e/Auth $ git show 4018bc7
commit 4018bc7bc870eb37aa35f40a0f612ca55a586045
Merge: a790392 674e39f
.....


Expected result: I should be able to see this autostash when `git stash list`



--
Best regards,
Eugen Konkov 


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

* Re: Can not list stash (git version 2.30.0)
  2021-04-07 17:49 Can not list stash (git version 2.30.0) Eugen Konkov
@ 2021-04-07 19:48 ` Jeff King
  0 siblings, 0 replies; 2+ messages in thread
From: Jeff King @ 2021-04-07 19:48 UTC (permalink / raw)
  To: Eugen Konkov; +Cc: Git Mailing List

On Wed, Apr 07, 2021 at 08:49:38PM +0300, Eugen Konkov wrote:

> I am in progress of rebasing
> 
> ~/e/Auth/Mojolicious/Plugin $ git rebase aa3376
> Created autostash: 4018bc7
> hint: Waiting for your editor to close the file...
> 
> 
> while I am in editor I switched to different console to view created autostash:
> 
> ~/e/Auth $ git stash list
> 
> and see nothing
> 
> but can view stash by its id:
> ~/e/Auth $ git show 4018bc7
> commit 4018bc7bc870eb37aa35f40a0f612ca55a586045
> Merge: a790392 674e39f
> .....

If you run with GIT_TRACE=1, you can see that the autostash feature uses
"git stash create" and not "git stash push". That creates the stash
commit but _doesn't_ push it onto the stash list.

So it's working as intended. The rationale comes from the very
first commit adding autostash, 587947750b (rebase: implement
--[no-]autostash and rebase.autostash, 2013-05-12), which says:

    The advantage of this approach is that we do not affect the normal
    stash's reflogs, making the autostash invisible to the end-user.  This
    means that you can use 'git stash' during a rebase as usual.

-Peff

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

end of thread, other threads:[~2021-04-07 19:48 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-07 17:49 Can not list stash (git version 2.30.0) Eugen Konkov
2021-04-07 19:48 ` Jeff King

git@vger.kernel.org list mirror (unofficial, one of many)

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://public-inbox.org/git
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 git git/ https://public-inbox.org/git \
		git@vger.kernel.org
	public-inbox-index git

Example config snippet for mirrors.
Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.version-control.git
	nntp://ou63pmih66umazou.onion/inbox.comp.version-control.git
	nntp://czquwvybam4bgbro.onion/inbox.comp.version-control.git
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.version-control.git
	nntp://news.gmane.io/gmane.comp.version-control.git
 note: .onion URLs require Tor: https://www.torproject.org/

code repositories for project(s) associated with this inbox:

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

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git