aboutsummaryrefslogtreecommitdiff
path: root/editors/code/src/commands/runnables.ts
diff options
context:
space:
mode:
authorBernardo <[email protected]>2019-04-13 21:13:21 +0100
committerBernardo <[email protected]>2019-04-19 19:54:36 +0100
commit1ae6571762cab605a84a731e10c89d8f3f00eef8 (patch)
tree1b73640a2f9e2e2ee85d06cf56994ee6fe97a5f0 /editors/code/src/commands/runnables.ts
parent0d39b1c3fa03a8032ea96be922fd62710f811aba (diff)
cargo watch start and stop commands
Diffstat (limited to 'editors/code/src/commands/runnables.ts')
-rw-r--r--editors/code/src/commands/runnables.ts7
1 files changed, 3 insertions, 4 deletions
diff --git a/editors/code/src/commands/runnables.ts b/editors/code/src/commands/runnables.ts
index c4df24c79..5790252b7 100644
--- a/editors/code/src/commands/runnables.ts
+++ b/editors/code/src/commands/runnables.ts
@@ -5,7 +5,7 @@ import * as vscode from 'vscode';
5import * as lc from 'vscode-languageclient'; 5import * as lc from 'vscode-languageclient';
6 6
7import { Server } from '../server'; 7import { Server } from '../server';
8import { CargoWatchProvider } from './cargo_watch'; 8import { CargoWatchProvider, registerCargoWatchProvider } from './cargo_watch';
9 9
10interface RunnablesParams { 10interface RunnablesParams {
11 textDocument: lc.TextDocumentIdentifier; 11 textDocument: lc.TextDocumentIdentifier;
@@ -137,7 +137,7 @@ export async function handleSingle(runnable: Runnable) {
137 */ 137 */
138export async function interactivelyStartCargoWatch( 138export async function interactivelyStartCargoWatch(
139 context: vscode.ExtensionContext 139 context: vscode.ExtensionContext
140) { 140): Promise<CargoWatchProvider | undefined> {
141 if (Server.config.cargoWatchOptions.enableOnStartup === 'disabled') { 141 if (Server.config.cargoWatchOptions.enableOnStartup === 'disabled') {
142 return; 142 return;
143 } 143 }
@@ -197,6 +197,5 @@ export async function interactivelyStartCargoWatch(
197 } 197 }
198 } 198 }
199 199
200 const validater = new CargoWatchProvider(); 200 return registerCargoWatchProvider(context.subscriptions);
201 validater.activate(context.subscriptions);
202} 201}