From 10297483241b18145d61bde0dd0dda16922eca0b Mon Sep 17 00:00:00 2001 From: Sven Efftinge Date: Wed, 18 Sep 2019 13:51:11 +0000 Subject: [PATCH] [plugin] map dependencies to vscode builtins properly Signed-off-by: Sven Efftinge --- packages/plugin-ext-vscode/src/node/scanner-vscode.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/plugin-ext-vscode/src/node/scanner-vscode.ts b/packages/plugin-ext-vscode/src/node/scanner-vscode.ts index 6f16ded66af85..204f287852230 100644 --- a/packages/plugin-ext-vscode/src/node/scanner-vscode.ts +++ b/packages/plugin-ext-vscode/src/node/scanner-vscode.ts @@ -28,6 +28,11 @@ export class VsCodePluginScanner extends TheiaPluginScanner implements PluginSca } getModel(plugin: PluginPackage): PluginModel { + // translate vscode builtins, as they are published with a prefix. See https://github.com/theia-ide/vscode-builtin-extensions/blob/master/src/republish.js#L50 + const built_prefix = '@theia/vscode-builtin-'; + if (plugin && plugin.name && plugin.name.startsWith(built_prefix)) { + plugin.name = plugin.name.substr(built_prefix.length); + } const result: PluginModel = { // see id definition: https://github.com/microsoft/vscode/blob/15916055fe0cb9411a5f36119b3b012458fe0a1d/src/vs/platform/extensions/common/extensions.ts#L167-L169 id: `${plugin.publisher.toLowerCase()}.${plugin.name.toLowerCase()}`,