TortoiseHG: undoing Guess Rename --> Accept Match
I'm using TortoiseHG and am trying to handle a renamed file. Unfortunately, I accidentally clicked Accept Match
for one of the files and want t开发者_如何学Co undo it. How do I do so without hurting the files I'm trying to commit?
In the commit dialog you can right-click on the added file, and select forget. Then the file is no longer marked as copy. When you want the file in the commit, you can add this file again.
I'm not sure what's different but for me, there is no "forget" option in this situation.
What worked for me is choosing "revert" on the added file (the one marked as 'A'). This removes the rename, but also restores the original file. (If you renamed asdf.txt
to fdsa.txt
you will now have two files with those names.)
You then have to manually delete the restored file, and you should be back where you started. Note that I find it's safer to delete files with Windows file explorer, since they will end up in the recycle bin. Files deleted from thg are deleted permanently.
精彩评论