Hi,

I'm not quite sure what you had expected. The revert isn't an undo, rather it 
adds extra commits that then remove the original content. This you will still 
see the original merge and its merged in conent, followed by the reverting 
commits that take them out again.

It may have been that you wanted (back then) to remove the merge by simply 
deleting it and moving the various heads back one commit as if it never 
happened, though that has the usual caveats about not changing history.

Have a look at the git revert man page, and its link to Linus's 
/revert-a-faulty-merge.txt for more details.

Philip
  ----- Original Message ----- 
  From: Béres Botond 
  To: git-users@googlegroups.com 
  Sent: Friday, September 20, 2013 6:21 PM
  Subject: [git-users] Merging a branch which has had a merge reverted in it 
ignored the revert


  Hi,

  I'd like to clarify a strange behaviour that I've encountered recently with 
Git.
  I've merged a feature branch "X" into a release branch, let's call it 
"release". This branch introduced a very difficult to debug issue and it 
contained a lot of commits so I've decided to revert the entire merge itself 
with 
git revert -m 1 <sha_of_merge>(see: 
http://git-scm.com/blog/2010/03/02/undoing-merges.html)

  This was fine but later on I've merged "release" into "master". And I've 
discovered that this merge actually merged into master also the changes from 
"X", like if it has never been reverted from "release".
  Is this expected behaviour or I must be missing something else?

  Thanks,

  Botond


  -- 
  You received this message because you are subscribed to the Google Groups 
"Git for human beings" group.
  To unsubscribe from this group and stop receiving emails from it, send an 
email to git-users+unsubscr...@googlegroups.com.
  For more options, visit https://groups.google.com/groups/opt_out.

-- 
You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to git-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to