Explain the difference between reverting and resetting.
Answer Posted / Sanjeev Mittal
Reverting in Git undoes specific changes by creating a new commit that cancels out the changes made by another commit. It leaves the commit history intact, which is useful for preserving information about what happened.nResetting, on the other hand, removes commits from the repository's history. This can be dangerous because it deletes data permanently. There are different ways to reset (soft, hard, mixed), but all of them affect the commit history.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers