I have been ploughing through the documentation of Visual Studio Code to figure out how to add multiple consecutive tasks to the tasks.json
file.
The tasks
array only allows for creating different arguments to the same command. In this example the command is echo
.
{
"version": "0.1.0",
"command": "echo",
"isShellCommand": true,
"args": [],
"showOutput": "always",
"echoCommand": true,
"suppressTaskName": true,
"tasks": [
{
"taskName": "hello",
"args": ["Hello World"]
},
{
"taskName": "bye",
"args": ["Good Bye"]
}
]
}
Does tasks.json allow several tasks to be executed consecutively? For example, tsc
followed by uglify
?
scripts
tag inpackage.json
. If you only need two or three consecutive commands you can use thepre
andpost
tags. If your build process becomes more complex you can use gulp or webpack. – Dandruff