我有大约 10 次提交,我需要从旧分支中挑选到大型 repo 上的当前分支。每次运行cherry-pick 命令时,都会得到以下信息:
$ git cherry-pick -x 11a77a55bf
Performing inexact rename detection: 0% (438032/938483560)
我第一次让它完成,大约需要 10-15 分钟。但它对我选择的每一个提交都这样做。有没有办法防止这种情况,至少对于当前命令?
我尝试设置 renameLimit 但没有帮助:
git -c diff.renameLimit=1 cherry-pick -x 11a77a55bf
Performing inexact rename detection: 0% (1259342/938483560)
最佳答案
git cherry-pick
在后台使用 merge 机制,它有自己的与重命名检测相关的配置:merge.renameLimit
.
git -c merge.renameLimit=1 cherry-pick -x 11a77a55bf
做你想做的。
关于git - 如何使用 git cherry-pick 跳过不精确的重命名检测,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65830756/