我的 cherry-pick 删除了目标上确实存在的单个文件,但它不会自动完成。为什么?
My cherry-pick deletes a single file, which does exist on the target, yet it does not auto complete. Why?
我有一个删除单个文件的提交:
C:\xyz\tmp55 [55 ↑1]> git show 17e645494
commit 17e6454949b44911bc42135e8f12c7f169ef835f
Author: Mark Kharitonov <bla-bla-bla>
Date: Mon Nov 12 11:05:18 2018 -0500
Some changes on MarkFeature
diff --git a/New Text Document.txt b/New Text Document.txt
deleted file mode 100644
index e69de29bb..000000000
文件存在于目标上:
C:\xyz\tmp55 [55 ↑1]> dir '.\New Text Document.txt' -Name
New Text Document.txt
但是 cherry-pick 无法自动完成:
C:\xyz\tmp55 [55 ↑1]> git cherry-pick 17e64549
warning: inexact rename detection was skipped due to too many files.
warning: you may want to set your merge.renamelimit variable to at least 7501 and retry the command.
error: could not apply 17e645494... Some changes on MarkFeature
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add <paths>' or 'git rm <paths>'
hint: and commit the result with 'git commit'
C:\xyz\tmp55 [55 ↑1 +0 ~0 -0 !1 | +0 ~0 -1 !]>
这是为什么?
文件的内容可能已更改,因此您会遇到冲突。想象一下这种情况。你在一个分支上删除了一个文件,在另一个分支上有人更改了文件....合并时应该是什么结果?预计会发生冲突。
我有一个删除单个文件的提交:
C:\xyz\tmp55 [55 ↑1]> git show 17e645494
commit 17e6454949b44911bc42135e8f12c7f169ef835f
Author: Mark Kharitonov <bla-bla-bla>
Date: Mon Nov 12 11:05:18 2018 -0500
Some changes on MarkFeature
diff --git a/New Text Document.txt b/New Text Document.txt
deleted file mode 100644
index e69de29bb..000000000
文件存在于目标上:
C:\xyz\tmp55 [55 ↑1]> dir '.\New Text Document.txt' -Name
New Text Document.txt
但是 cherry-pick 无法自动完成:
C:\xyz\tmp55 [55 ↑1]> git cherry-pick 17e64549
warning: inexact rename detection was skipped due to too many files.
warning: you may want to set your merge.renamelimit variable to at least 7501 and retry the command.
error: could not apply 17e645494... Some changes on MarkFeature
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add <paths>' or 'git rm <paths>'
hint: and commit the result with 'git commit'
C:\xyz\tmp55 [55 ↑1 +0 ~0 -0 !1 | +0 ~0 -1 !]>
这是为什么?
文件的内容可能已更改,因此您会遇到冲突。想象一下这种情况。你在一个分支上删除了一个文件,在另一个分支上有人更改了文件....合并时应该是什么结果?预计会发生冲突。