mirror of
https://github.com/denoland/deno.git
synced 2024-12-22 07:14:47 -05:00
661aa22c03
This commit adds support for "dependencies" in `deno task` subcommand: ```jsonc { "tasks": { "build": "deno run -RW build.ts", "generate": "deno run -RW generate.ts", "serve": { "command": "deno run -RN server.ts", "dependencies": ["build", "generate"] } } } ``` Executing `deno task serve` will first execute `build` and `generate` tasks (in parallel) and once both complete the `serve` task will be executed. Number of tasks run in parallel is equal to the no of cores on the machine, and respects `DENO_JOBS` env var if one is specified. Part of https://github.com/denoland/deno/issues/26462 --------- Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com> Co-authored-by: Marvin Hagemeister <marvin@deno.com>
28 lines
442 B
Text
28 lines
442 B
Text
{
|
|
// a
|
|
// / \
|
|
// b c
|
|
// | |
|
|
// | d
|
|
// \ /
|
|
// e
|
|
"tasks": {
|
|
"a": {
|
|
"command": "deno run a.js",
|
|
"dependencies": ["b", "c"]
|
|
},
|
|
"b": {
|
|
"command": "deno run b.js",
|
|
"dependencies": ["e"]
|
|
},
|
|
"c": {
|
|
"command": "deno run c.js",
|
|
"dependencies": ["d"]
|
|
},
|
|
"d": {
|
|
"command": "deno run d.js",
|
|
"dependencies": ["e"]
|
|
},
|
|
"e": "deno run e.js"
|
|
}
|
|
}
|