MCPcopy Index your code
hub / github.com/WebFreak001/code-debug / toRemotePath

Method toRemotePath

src/source_file_map.ts:92–106  ·  view source on GitHub ↗
(localPath: string)

Source from the content-addressed store, hash-verified

90 }
91
92 public toRemotePath (localPath: string): string {
93 const normalizedLocalPath = this.nativePath.normalize(localPath);
94 const mapping: Mapping | undefined =
95 this.pathMatch("local", this.nativePath.caseSensitive, normalizedLocalPath);
96
97 if (mapping) {
98 const pathSuffix = normalizedLocalPath.substring(mapping.local.length);
99 // Try to detect remote path.
100 const debuggerPath = this.toPathKind(mapping.remote);
101 return debuggerPath.join(mapping.remote, pathSuffix);
102 }
103
104 // No mapping found, so return unmapped path.
105 return localPath;
106 }
107}

Callers 3

setBreakPointsRequestMethod · 0.80
gotoTargetsRequestMethod · 0.80

Calls 2

pathMatchMethod · 0.95
toPathKindMethod · 0.95

Tested by

no test coverage detected