Move task provider to the latest version

This commit is contained in:
Dirk Baeumer
2018-09-04 14:47:27 +02:00
parent c539b99087
commit 5db93b4042
2 changed files with 9 additions and 2 deletions

View File

@ -5,7 +5,7 @@
"version": "0.0.1",
"publisher": "ms-vscode",
"engines": {
"vscode": "^1.23.0"
"vscode": "^1.26.0"
},
"categories": [
"Other"

View File

@ -22,7 +22,7 @@ export function activate(_context: vscode.ExtensionContext): void {
fileWatcher.onDidChange(() => rakePromise = undefined);
fileWatcher.onDidCreate(() => rakePromise = undefined);
fileWatcher.onDidDelete(() => rakePromise = undefined);
taskProvider = vscode.workspace.registerTaskProvider('rake', {
taskProvider = vscode.tasks.registerTaskProvider('rake', {
provideTasks: () => {
if (!rakePromise) {
rakePromise = getRakeTasks();
@ -69,7 +69,14 @@ function getOutputChannel(): vscode.OutputChannel {
}
interface RakeTaskDefinition extends vscode.TaskDefinition {
/**
* The task name
*/
task: string;
/**
* The rake file containing the task
*/
file?: string;
}