MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / install

Method install

src/installer/targets/cursor.ts:109–127  ·  view source on GitHub ↗
(loc: Location, _opts: InstallOptions)

Source from the content-addressed store, hash-verified

107 }
108
109 install(loc: Location, _opts: InstallOptions): WriteResult {
110 const files: WriteResult['files'] = [];
111
112 files.push(writeMcpEntry(loc));
113
114 // We no longer write `.cursor/rules/codegraph.mdc` — the codegraph
115 // usage guidance ships in the MCP server's `initialize` response,
116 // the single source of truth (issue #529). Strip a rules file a
117 // previous install created so an upgrade self-heals.
118 if (loc === 'local') {
119 const rulesCleanup = removeRulesEntry();
120 if (rulesCleanup.action === 'removed') files.push(rulesCleanup);
121 }
122
123 return {
124 files,
125 notes: ['Restart Cursor for MCP changes to take effect.'],
126 };
127 }
128
129 uninstall(loc: Location): WriteResult {
130 const files: WriteResult['files'] = [];

Callers

nothing calls this directly

Calls 3

removeRulesEntryFunction · 0.85
pushMethod · 0.80
writeMcpEntryFunction · 0.70

Tested by

no test coverage detected