最佳答案
这是我的文件夹“有些文件夹”的历史记录
$ git log somefolder
commit 89cd
More changes to somefolder
commit ef47a
Updating somefolder and other stuff
commit e095
Bugs fixed in somefolder
我想恢复一些文件夹回到“错误修复在一些文件夹”提交。
由于第二次提交涉及某个文件夹之外的更改,因此我不想恢复此提交。
我想最安全的方法是在提交 e095和89cd 之间创建一个只应用于某个文件夹的 diff/patch,然后应用该补丁。我该怎么做?