Skip to content

Commit f3765fb

Browse files
authored
Merge pull request microsoft#211244 from microsoft/benibenj/experimental-yak
Fix custom labels with absolute pattern
2 parents 070a36d + 5b025ab commit f3765fb

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/vs/workbench/services/editor/common/customEditorLabelService.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@ export class CustomEditorLabelService extends Disposable implements ICustomEdito
177177

178178
private getNthDirname(path: string, filename: string, n: number): string | undefined {
179179
// grand-parent/parent/filename.ext1.ext2 -> [grand-parent, parent]
180+
path = path.startsWith('/') ? path.slice(1) : path;
180181
const pathFragments = path.split('/');
181182

182183
const length = pathFragments.length;

0 commit comments

Comments
 (0)