All of lore.kernel.org
 help / color / mirror / Atom feed
* git stash deletes/drops changes of "assume-unchanged" files
@ 2010-06-04 16:24 Adeodato Simó
  2013-05-23 16:57 ` git stash deletes/drops changes of Jim Greenleaf
  0 siblings, 1 reply; 20+ messages in thread
From: Adeodato Simó @ 2010-06-04 16:24 UTC (permalink / raw)
  To: git

Hello (and please CC me on replies).

I was unpleasantly surprised to discover yesterday that doing `git
stash` on a repository where I had previously run `git update-index
--assume-unchanged FOO` completely lost all changes I had in file FOO.

I understand the behavior is logical from the way git-stash is
implemented, but it strikes as very undesirable behavior to me. Does
somebody think something could be done to change it? In my opinion, both
including in the stash changes in FOO, or just leaving them in the
working tree, would be better alternatives.

Thoughts?

-8<-

% git init
% echo file1 contents >file1; echo file2 contents >file2
% git add file1 file2; git commit -m Initial.

% echo changes for file2 >>file2
% echo some other changes to file 1 >>file1
% git update-index --assume-unchanged file1

% git stash
% cat file1
file1 contents
% git stash show -p
--- a/file2
+++ b/file2
@@ -1 +1,2 @@
 file2 contents
+changes for file2

-8<-

-- 
- Are you sure we're good?
- Always.
        -- Rory and Lorelai

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

end of thread, other threads:[~2013-05-24 16:02 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-04 16:24 git stash deletes/drops changes of "assume-unchanged" files Adeodato Simó
2013-05-23 16:57 ` git stash deletes/drops changes of Jim Greenleaf
2013-05-23 22:10   ` Thomas Rast
2013-05-23 22:49     ` Junio C Hamano
2013-05-23 22:56       ` Thomas Rast
2013-05-23 23:20         ` Junio C Hamano
2013-05-24 15:25           ` Phil Hord
2013-05-24 15:34             ` Jim Greenleaf
2013-05-24 15:38               ` John Keeping
2013-05-24 15:42                 ` Jim Greenleaf
2013-05-24 16:01                   ` John Keeping
2013-05-23 23:57         ` Petr Baudis
2013-05-24  8:22           ` John Keeping
2013-05-24  9:40             ` Petr Baudis
2013-05-24 10:06               ` John Keeping
2013-05-24 10:14                 ` Petr Baudis
2013-05-24 10:40                   ` John Keeping
2013-05-24 11:03                     ` Petr Baudis
2013-05-24 12:42                       ` John Keeping
2013-05-24 14:26         ` Stephen Bash

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.