1
0
mirror of https://github.com/go-task/task.git synced 2025-08-10 22:42:19 +02:00

Possibility to call another task

This commit is contained in:
Andrey Nering
2017-03-25 15:26:42 -03:00
parent 0db3e9a05d
commit 59306cda38
5 changed files with 87 additions and 5 deletions

View File

@@ -141,6 +141,28 @@ task2:
Will stop at the moment the dependencies of `task2` are executed.
### Calling a task from another task
When a task has many dependencies, they are executed concurrently. This will
often result in a faster build pipeline. But in some situations you may need
to call other tasks serially. For this just prefix a command with `^`:
```yml
a-task:
cmds:
- ^another-task
- ^even-another-task
- echo "Both done"
another-task:
cmds:
- ...
even-another-task:
cmds:
- ...
```
### Prevent task from running when not necessary
If a task generates something, you can inform Task the source and generated