mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-08-29 03:44:06 +08:00
fix: include lowercase 'resolve merge conflicts' in rerere training grep
The training grep only matched uppercase 'Resolve merge conflict', missing the lowercase convention used by most historical upstream merges. This dropped ~70 past merges from the rerere training set on kilocode, leaving the cache mostly empty and causing rerere to miss resolutions that involve the opencode -> kilo rename.
This commit is contained in:
@@ -148,8 +148,12 @@ async function main() {
|
||||
|
||||
// Train rerere from past upstream merge commits so the cache is populated
|
||||
// even on a fresh clone. This replays past merges to learn their resolutions.
|
||||
// The grep covers both the current convention ("merge: upstream vX.Y.Z") and the
|
||||
// historical convention used by older upstream merges ("[Rr]esolve merge conflicts").
|
||||
// Without the lowercase alternative, ~70 past merges are dropped from training on
|
||||
// this repo, since most older resolution commits use a lowercase "resolve".
|
||||
logger.info("Training rerere cache from past merge history...")
|
||||
const learned = await git.trainRerere("merge: upstream\\|Resolve merge conflict")
|
||||
const learned = await git.trainRerere("merge: upstream\\|[Rr]esolve merge conflict")
|
||||
if (learned > 0) {
|
||||
logger.success(`Learned ${learned} conflict resolution(s) from history`)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user