File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -606,7 +606,8 @@ export function timeout(millis: number): Promise<void> {
606
606
}
607
607
608
608
/**
609
- * Expands ~ to homedir in non-Windows platform and resolves ${workspaceFolder} or ${workspaceRoot}
609
+ * Expands ~ to homedir in non-Windows platform and resolves
610
+ * ${workspaceFolder}, ${workspaceRoot} and ${workspaceFolderBasename}
610
611
*/
611
612
export function resolvePath ( inputPath : string , workspaceFolder ?: string ) : string {
612
613
if ( ! inputPath || ! inputPath . trim ( ) ) {
@@ -621,6 +622,7 @@ export function resolvePath(inputPath: string, workspaceFolder?: string): string
621
622
622
623
if ( workspaceFolder ) {
623
624
inputPath = inputPath . replace ( / \$ { workspaceFolder} | \$ { workspaceRoot} / g, workspaceFolder ) ;
625
+ inputPath = inputPath . replace ( / \$ { workspaceFolderBasename} / g, path . basename ( workspaceFolder ) ) ;
624
626
}
625
627
return resolveHomeDir ( inputPath ) ;
626
628
}
You can’t perform that action at this time.
0 commit comments