Files
azuredatastudio/extensions/import/src/main.ts
Aasim Khan 046995f2a5 Flat File Import says command not found on first run (#10081) (#10184)
* Changed the activation event from onCommand to startup "*"

* Refractored some code to fix the issue

* Made some PR related changes and fixed a condition where the same error was occurring when the flatFileImport has to download binaries from the internet.

* Reverted activation event back to previous state as it had no effect.

* Made changes mentioned in the PR

Co-authored-by: Aasim Shahnawaz Khan <aaskhan@microsoft.com>
2020-04-28 18:15:20 -07:00

27 lines
947 B
TypeScript

/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the Source EULA. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import * as vscode from 'vscode';
import ControllerBase from './controllers/controllerBase';
import MainController from './controllers/mainController';
let controllers: ControllerBase[] = [];
export async function activate(context: vscode.ExtensionContext): Promise<boolean> {
// Start the main controller
let mainController = new MainController(context);
controllers.push(mainController);
context.subscriptions.push(mainController);
await mainController.activate();
return true;
}
export function deactivate() {
for (let controller of controllers) {
controller.deactivate();
}
}