code_junkie

How do you remove a specific revision in the git history?

Nov 10th, 2011
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. master
  2.  
  3. git rebase --onto master~3 master~2 master
  4.  
  5. 1---2---3---4---5 master
  6.  
  7. 1---2---4'---5' master
  8.  
  9. E---F---G---H---I---J topicA
  10.  
  11. git rebase --onto topicA~5 topicA~3 topicA
  12.  
  13. E---H'---I'---J' topicA
  14.  
  15. git rebase --onto <commit-id>^ <commit-id> HEAD
Add Comment
Please, Sign In to add comment