Create a new VSCode extension for different tasks
Asked Answered
K

0

6

I want to create a custom VS Code task with my own schema docs
vscode task

e.g. A new tree view which is empty and when user click on + button (a new tree view with button which is similar source code tree like, add file, add folder, etc but just with + button which create a new tasks from two options) he got list of tasks when he click on specific task it create a tasks.json (if it doesn't exist) file with schema which is related to the task he choose from the list like tasks1 and if he choose task2 he get different entry in the tasks.json that he need to edit.

The trick here, that each task should add different entry in the tasks.json file which is generated to the user

e.g.

if user choose task1 he need to fill (a new entry in the task.json)

username
password

And if he choose task2

system
endpoint

Is it possible to do it in VS Code? Any example with for this can will be helpful.

I've tried the following even it doesn't fit the same scenario I need exactly (different tasks entry in the tasks.json file) however it doesn't add any task on the task.json. More here: https://github.com/microsoft/vscode-extension-samples/tree/master/task-provider-sample

Kermes answered 22/2, 2020 at 20:49 Comment(6)
Please stop making trivial edits to this post in an attempt to "bump" it. If you are substantively improving the post, or adding new information, then that is a fine reason to edit. But several of your last edits were just adding filler or nonsense that doesn't belong in the first place.Modular
@CodyGray - you edited also :) , I didnt know that "bump" functionality :) thanks for notice.Kermes
This question is too broad, basically you're asking for a code session that walk you through vscode API and teach you how to create an entire extension for your use case. This simply is too much to ask on stackoverflow. Show people what you've done so far, where you got stuck, ask about more specific problem.Human
@Human - I basically took github.com/microsoft/vscode-extension-samples/tree/master/… and try to adopt it without success, what I need is basically a way to add my new entry to the tasks.json file, I didnt manage to do it with the taskprovider API but as I need to vscode extension maybe I miss somethingKermes
@Human - if someone can take this github.com/microsoft/vscode-extension-samples/tree/master/… , and add just what I need , define two different tasks this is sufficient, as this is a bit tricky I provided a bounty, hope you could help...thanks!Kermes
I completely, agree with @Human and unfortunately as of your last comment you also agree with him, stackoverflow isn't a place for asking someone to just add a couple of tasks and be provided with a bounty as a paymentEpiglottis

© 2022 - 2024 — McMap. All rights reserved.