git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* Unstaging during a merge conflict
@ 2012-10-02  1:13 Matt McClellan
  2012-10-02 17:24 ` Junio C Hamano
  2012-10-03 22:01 ` Jeff King
  0 siblings, 2 replies; 3+ messages in thread
From: Matt McClellan @ 2012-10-02  1:13 UTC (permalink / raw)
  To: git

We had an issue at our organization where changes were reverted when a
user was merging his local repo with the remote repo changes.  The
merge conflicted and he unstaged all the changes that were not a
conflict, he then resolved the conflict and added just the conflicted
file and committed.  The end result was that he reverted every change
from his last pull of the remote to his merge point.  The problem I'm
having how hard it is to see this problem as both git show and git log
on the merge commit do not show any reverted files.  It was found by
diffing his commit to each of the parents and seeing the opposite of
what we expected in the patch output.

Anybody have ideas how we can prevent these mistakes?  While we are
going to do more training, a hard stop that wouldn't even let these
make it to remote would be preferred.

I've done this using git add --interactive then reverting a files
changes, though the actual crime was done using egit staging tool.  It
seems the command line won't let you unstage changes but gui tools and
interactive tools seem to allow it.

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

end of thread, other threads:[~2012-10-04 21:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-02  1:13 Unstaging during a merge conflict Matt McClellan
2012-10-02 17:24 ` Junio C Hamano
2012-10-03 22:01 ` Jeff King

Code repositories for project(s) associated with this public inbox

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

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 read-only IMAP folder(s) and NNTP newsgroup(s).