MCPcopy
hub / github.com/ollm/OpenComic / splitPath

Function splitPath

scripts/file-manager.js:3159–3167  ·  view source on GitHub ↗
(path)

Source from the content-addressed store, hash-verified

3157}
3158
3159function splitPath(path)
3160{
3161 const first = app.extract(/^([\\\/]*[^\\\/]+)[\\\/]*/, path);
3162 const segments = path.replace(/^([\\\/]*[^\\\/]+)[\\\/]*/, '').split(p.sep).filter(i => i);
3163
3164 segments.unshift(first);
3165
3166 return segments;
3167}
3168
3169function isParentPath(parentPath, fullPath)
3170{

Callers 8

fileFunction · 0.85
fileCompressedFunction · 0.85
realPathFunction · 0.85
firstCompressedFileFunction · 0.85
lastCompressedFileFunction · 0.85
allCompressedFilesFunction · 0.85
containsCompressedFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected