1
0
mirror of https://github.com/go-task/task.git synced 2025-11-29 22:48:03 +02:00

v3: Allow interpolation on "includes"

The idea is to allow manual inclusion of a OS-dependant Taskfile, since it's
not automatically included anymore.
This commit is contained in:
Andrey Nering
2020-05-17 16:03:03 -03:00
parent 191c34c9c4
commit 9f0f18c5c4
6 changed files with 33 additions and 4 deletions

View File

@@ -13,6 +13,7 @@ includes:
included_taskfile_with_dir:
taskfile: ./module2/Taskfile.yml
dir: ./module2
included_os: ./Taskfile_{{OS}}.yml
tasks:
default:
@@ -24,6 +25,7 @@ tasks:
- task: included_taskfile_without_dir:gen_dir
- task: included_with_dir:gen_file
- task: included_taskfile_with_dir:gen_dir
- task: included_os:gen
gen:
cmds:

4
testdata/includes/Taskfile_darwin.yml vendored Normal file
View File

@@ -0,0 +1,4 @@
version: '3'
tasks:
gen: echo 'os' > os_include.txt

4
testdata/includes/Taskfile_linux.yml vendored Normal file
View File

@@ -0,0 +1,4 @@
version: '3'
tasks:
gen: echo 'os' > os_include.txt

View File

@@ -0,0 +1,4 @@
version: '3'
tasks:
gen: echo 'os' > os_include.txt