MCPcopy Index your code
hub / github.com/sourcebot-dev/sourcebot / normalizeTreePath

Function normalizeTreePath

packages/web/src/features/tools/listTree.ts:206–209  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

204};
205
206const normalizeTreePath = (path: string): string => {
207 const withoutLeading = path.replace(/^\/+/, '');
208 return withoutLeading.replace(/\/+$/, '');
209}
210
211const joinTreePath = (parentPath: string, name: string): string => {
212 if (!parentPath) {

Callers 1

listTree.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected