mirror of
https://github.com/Microsoft/vscode
synced 2024-10-02 09:18:59 +00:00
Add ${/} as a shorter alias for ${pathSeparator} predefined variable (#200750)
Fixes #180827
This commit is contained in:
parent
81178e2113
commit
86504b9c9c
|
@ -66,7 +66,7 @@ function registerVariableCompletions(pattern: string): vscode.Disposable {
|
|||
{ label: 'fileBasename', detail: vscode.l10n.t("The current opened file's basename") },
|
||||
{ label: 'fileBasenameNoExtension', detail: vscode.l10n.t("The current opened file's basename with no file extension") },
|
||||
{ label: 'defaultBuildTask', detail: vscode.l10n.t("The name of the default build task. If there is not a single default build task then a quick pick is shown to choose the build task.") },
|
||||
{ label: 'pathSeparator', detail: vscode.l10n.t("The character used by the operating system to separate components in file paths") },
|
||||
{ label: 'pathSeparator', detail: vscode.l10n.t("The character used by the operating system to separate components in file paths. Is also aliased to '/'.") },
|
||||
{ label: 'extensionInstallFolder', detail: vscode.l10n.t("The path where an an extension is installed."), param: 'publisher.extension' },
|
||||
].map(variable => ({
|
||||
label: `\${${variable.label}}`,
|
||||
|
|
|
@ -107,7 +107,8 @@ export enum VariableKind {
|
|||
FileDirnameBasename = 'fileDirnameBasename',
|
||||
ExecPath = 'execPath',
|
||||
ExecInstallFolder = 'execInstallFolder',
|
||||
PathSeparator = 'pathSeparator'
|
||||
PathSeparator = 'pathSeparator',
|
||||
PathSeparatorAlias = '/'
|
||||
}
|
||||
|
||||
export class VariableError extends Error {
|
||||
|
|
|
@ -368,6 +368,7 @@ export class AbstractVariableResolverService implements IConfigurationResolverSe
|
|||
return match;
|
||||
}
|
||||
case 'pathSeparator':
|
||||
case '/':
|
||||
return paths.sep;
|
||||
|
||||
default:
|
||||
|
|
Loading…
Reference in a new issue