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

Method normalize

src/mcp/tools.ts:8261–8261  ·  view source on GitHub ↗
(p: string)

Source from the content-addressed store, hash-verified

8259 opts: { offset?: number; limit?: number; symbolsOnly?: boolean } = {},
8260 ): Promise<ToolResult> {
8261 const normalize = (p: string) => p.replace(/\\/g, '/').replace(/^(?:\.?\/+)+/, '').replace(/\/+$/, '');
8262 const allFiles = cg.getFiles();
8263 if (allFiles.length === 0) return this.textResult('No files indexed. Run `codegraph index` first.');
8264

Callers 15

resolveGitDirFunction · 0.80
emitRubyRequireRefsMethod · 0.80
indexedSpellingFunction · 0.80
resolveViaImportFunction · 0.80
resolveIncludeFunction · 0.80
pathDependenciesFunction · 0.80
resolveDartUriFunction · 0.80
resolveIncludeFunction · 0.80
templatePathForFunction · 0.80
expandMembersFunction · 0.80
normalizeRelFunction · 0.80
resolvePhpPathFunction · 0.80

Calls

no outgoing calls

Tested by 1

outsideFunction · 0.64