fix: pass filePath in setupRerereAdapter stale MERGE_HEAD cleanup
cleanupMergeState() without a filePath runs bare `git reset`, which resets the entire index and can stage deletions of unrelated files. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -58,7 +58,7 @@ export function setupRerereAdapter(
|
||||
|
||||
// Clean up stale MERGE_HEAD from a previous crash
|
||||
if (fs.existsSync(path.join(gitDir, 'MERGE_HEAD'))) {
|
||||
cleanupMergeState();
|
||||
cleanupMergeState(filePath);
|
||||
}
|
||||
|
||||
// Hash objects into git object store
|
||||
|
||||
Reference in New Issue
Block a user