git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Bug: stash staged file move loses original file deletion
@ 2016-12-05 14:37 Matthew Patey
  2016-12-06 14:24 ` Jeff King
  0 siblings, 1 reply; 13+ messages in thread
From: Matthew Patey @ 2016-12-05 14:37 UTC (permalink / raw)
  To: git

Git version 2.8.0 (sorry can't update to more recent on my machine) on Ubuntu.

After moving a file, if the new file is in the index but the deletion
of the old file is not staged, git stash loses the deletion operation.
Repro:

1. git mv a b
This will have both the "deletion" and the "file added" in the index

2. git stash; git stash pop
Now file a is still in the index, but file b deletion is not staged.

3. git stash; git stash show -v
This will show that the deletion operation is not in the stash

4. git stash pop
Again confirms the issue, file a is in the index, but file b is
present and unmodified in the working directory.

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

end of thread, other threads:[~2016-12-06 20:36 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-12-05 14:37 Bug: stash staged file move loses original file deletion Matthew Patey
2016-12-06 14:24 ` Jeff King
     [not found]   ` <CAFQpxx+PJ3FSoH9DFWyEw+ZLagji9Qou+aY9EB8A+=t+QX0o2A@mail.gmail.com>
2016-12-06 15:25     ` Jeff King
2016-12-06 15:41       ` [PATCH] stash: disable renames when calling git-diff Jeff King
2016-12-06 19:20         ` Junio C Hamano
2016-12-06 19:31           ` Jeff King
2016-12-06 19:51             ` Junio C Hamano
2016-12-06 20:11               ` Jeff King
2016-12-06 20:22                 ` Junio C Hamano
2016-12-06 20:26                   ` Jeff King
2016-12-06 20:31                   ` Junio C Hamano
2016-12-06 20:25                 ` Jeff King
2016-12-06 20:36                   ` Junio C Hamano

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 NNTP newsgroup(s).