2

How to re-apply already reverted back changes in git

  1. Made some changes to "git push"
  2. git revert "2398239" - later
  3. Made some changes to "git push"
  4. I would like to pullback changes from the revert in [2]

How should I do this?

Rpj
  • 4,194
  • 12
  • 43
  • 94
  • 1
    You could simply cherry-pick the old commit: `git cherry-pick 2398239`, although reverting the revert as suggested would probably be bit more explicit. – Mykola Gurov Feb 18 '15 at 07:28

1 Answers1

3

When doing the step 2, you will get a new commit ID. You can revert that commit ID. This is basiclly reverting the revert and same as reverting a comit.

Made some changes to "git push" //commit id "2398239"
git revert "2398239" - later // commit id "2345678"
Made some changes to "git push"
git revert "2345678"
Abimaran Kugathasan
  • 29,154
  • 11
  • 70
  • 102