More second command to Ctx

This commit is contained in:
Aleksey Kladov 2019-12-30 14:53:43 +01:00
parent e53ccb6e99
commit 29e86c0c72
4 changed files with 14 additions and 11 deletions

View file

@ -15,11 +15,8 @@ let ctx!: Ctx;
export async function activate(context: vscode.ExtensionContext) {
ctx = new Ctx(context);
ctx.registerCommand(
'analyzerStatus',
commands.analyzerStatus
);
ctx.registerCommand('analyzerStatus', commands.analyzerStatus);
ctx.registerCommand('collectGarbage', commands.collectGarbage);
function disposeOnDeactivation(disposable: vscode.Disposable) {
context.subscriptions.push(disposable);
@ -58,9 +55,6 @@ export async function activate(context: vscode.ExtensionContext) {
}
// Commands are requests from vscode to the language server
registerCommand('rust-analyzer.collectGarbage', () =>
Server.client.sendRequest<null>('rust-analyzer/collectGarbage', null),
);
registerCommand(
'rust-analyzer.matchingBrace',
commands.matchingBrace.handle,