diff --git a/CHANGELOG.md b/CHANGELOG.md index e5d6e846f1..5ce33392f6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,8 @@ (#1415, #1547 by @pd93). - Refactored how Task reads, parses and merges Taskfiles using a DAG (#1563, #1607 by @pd93). +- Fix a bug which stopped tasks from using `stdin` as input (#1593, #1623 by + @pd03). - Fix error when a file or directory in the project contained a special char like `&`, `(` or `)` (#1551, #1584 by @andreynering). - Added alias `q` for template function `shellQuote` (#1601, #1603 by @vergenzt) diff --git a/website/docs/usage.mdx b/website/docs/usage.mdx index 50a010e161..b5088ce87d 100644 --- a/website/docs/usage.mdx +++ b/website/docs/usage.mdx @@ -121,13 +121,14 @@ tasks: ### Reading a Taskfile from stdin Taskfile also supports reading from stdin. This is useful if you are generating -Taskfiles dynamically and don't want write them to disk. This works just like -any other program that supports stdin. For example: +Taskfiles dynamically and don't want write them to disk. To tell task to read +from stdin, you must specify the `-t/--taskfile` flag with the special `-` +value. You may then pipe into Task as you would any other program: ```shell -task < <(cat ./Taskfile.yml) +task -t - <(cat ./Taskfile.yml) # OR -cat ./Taskfile.yml | task +cat ./Taskfile.yml | task -t - ``` ## Environment variables