diff --git a/src/extension.ts b/src/extension.ts index 35dd3bef5..b5dca1fe8 100644 --- a/src/extension.ts +++ b/src/extension.ts @@ -46,6 +46,9 @@ export async function activate(context: vscode.ExtensionContext): Promise await migrateLegacySettings(context); + // always register commands needed to control terraform-ls + context.subscriptions.push(new TerraformLSCommands()); + if (config('terraform').get('languageServer.enable') === false) { reporter.sendTelemetryEvent('disabledTerraformLS'); return; @@ -94,11 +97,7 @@ export async function activate(context: vscode.ExtensionContext): Promise ]); // these need the LS to function, so are only registered if enabled - context.subscriptions.push( - new GenerateBugReportCommand(context), - new TerraformLSCommands(), - new TerraformCommands(client, reporter), - ); + context.subscriptions.push(new GenerateBugReportCommand(context), new TerraformCommands(client, reporter)); await startLanguageServer(context); }