I'm in charge of sound design, but not an expert with git.
I used Sourcetree for data sharing with the developer because he suggested it.
Today, one of my files is significantly more than 100mb, so it stuck to commit.
The developer said, "you need to revert it," and I did it.
And my work was gone.
How to cancel or reset "revert"?
I tried the reflog method, but it isn't work.
Hello @이이담 and welcome to the Community!
In git there are different ways to revert a commit :
You can find more details about the difference between revert and reset in the articles Git Revert and Git Reset.
From your description, it seems like you did the revert from Sourcetree, which uses the git revert method.
In this case, a new commit (the "revert" commit) should have been create when you first reverted the changes. You should be able to select the same Reverse option on that "revert" commit to undo the changes, by right-clicking on the commit and selecting the Reverse option :
This would create a new commit that should bring back the files/changes prior to the first revert.
Let me know in case you have any questions.
Thank you, @이이담 !
Patrik S
Thanks for your kindness :)
I had have already tried your method, but it didn't work.
maybe my old commit made me stuck into error.
So I found the another way with my friend who knows about sourcetree well.
In my case, I tried 3 ways
2) reset --soft HEAD{0} for cancel revert,
3) reset the master branch.
4) and git restore --staged .
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.