Skip to content

Commit d88949d

Browse files
committed
Merge branch 'tg/rerere-doc-updates'
Clarify a part of technical documentation for rerere. * tg/rerere-doc-updates: rerere: add note about files with existing conflict markers rerere: mention caveat about unmatched conflict markers
2 parents 881c019 + f427869 commit d88949d

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

Documentation/git-rerere.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,12 @@ would conflict the same way as the test merge you resolved earlier.
211211
'git rerere' will be run by 'git rebase' to help you resolve this
212212
conflict.
213213

214+
[NOTE] 'git rerere' relies on the conflict markers in the file to
215+
detect the conflict. If the file already contains lines that look the
216+
same as lines with conflict markers, 'git rerere' may fail to record a
217+
conflict resolution. To work around this, the `conflict-marker-size`
218+
setting in linkgit:gitattributes[5] can be used.
219+
214220
GIT
215221
---
216222
Part of the linkgit:git[1] suite

Documentation/technical/rerere.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,10 @@ version, and the sorting the conflict hunks, both for the outer and the
149149
inner conflict. This is done recursively, so any number of nested
150150
conflicts can be handled.
151151

152+
Note that this only works for conflict markers that "cleanly nest". If
153+
there are any unmatched conflict markers, rerere will fail to handle
154+
the conflict and record a conflict resolution.
155+
152156
The only difference is in how the conflict ID is calculated. For the
153157
inner conflict, the conflict markers themselves are not stripped out
154158
before calculating the sha1.

0 commit comments

Comments
 (0)