actboy168 / vscode-tasks

MIT License
37 stars 14 forks source link

.code-workspace defined tasks not appearing #21

Closed poseva closed 3 years ago

poseva commented 4 years ago

Hello!

I saw that instead of .vscode/tasks.json you have defined the tasks in .code-workspace, the Tasks extensions does not display them in the status bar. Is this not implemented ?

Thank you in advance!

Best regards, Sebastian

actboy168 commented 4 years ago

I do not understand your question. Can you elaborate more?

poseva commented 4 years ago

Tasks can be defined either in a file tasks.json OR directly in a myproject.code-workspace file that contains workspace related settings.

If I define the tasks, in tasks.json file, VS Code recognizes the tasks (Ctrl+Shift+P will show the tasks) and also your extension displays the tasks as buttons. Everything works nice.

If I delete the tasks.json file and move the tasks in myproject.code-workspace file, VS code recognizes the tasks (Ctrl+Shift+P will show the tasks) but your extension does NOT show them as buttons.

Is this extension capable of reading tasks from myproject.code-workspace files ?

actboy168 commented 4 years ago

VSCode's support for workspace tasks is not yet complete. So this is not yet possible.

Once VSCode is ready, I will implement it.

sandym commented 3 years ago

This now work, but only if you also have a .vscode/tasks.json in your folder. If tasks.json is not present, tasks in the .code-workspace are ignored.

sandym commented 3 years ago

This, in package.json "activationEvents": [ "workspaceContains:.vscode/tasks.json" ], need to change to: "activationEvents": [ "*" ],