fix: avoid cursor nested AGENTS context pollution

This commit is contained in:
Affaan Mustafa
2026-04-30 00:33:51 -04:00
committed by Affaan Mustafa
parent 95ce9eaaeb
commit d49f0329a9
2 changed files with 36 additions and 0 deletions

View File

@@ -133,6 +133,12 @@ module.exports = createInstallTargetAdapter({
destinationPath: path.join(targetRoot, 'mcp.json'),
});
if (sourceRelativePath === 'AGENTS.md') {
// Cursor treats nested AGENTS.md files as directory context; do not
// install ECC's root project identity into a host project's .cursor/.
return [];
}
if (sourceRelativePath === 'rules') {
return takeUniqueOperations(createFlatRuleOperations({
moduleId: module.id,