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

fix: propagate include vars in multi-level includes (#1256)

This commit is contained in:
Hudson Clark
2023-07-08 08:42:38 -06:00
committed by GitHub
parent 2a0c99b5d8
commit 8a0689328b
6 changed files with 67 additions and 1 deletions

View File

@@ -0,0 +1,17 @@
version: "3"
includes:
lib:
taskfile: lib/Taskfile.yml
internal: true
foo:
taskfile: foo/Taskfile.yml
bar:
taskfile: bar/Taskfile.yml
tasks:
default:
cmds:
- task: lib:greet
- task: foo:lib:greet
- task: bar:lib:greet

View File

@@ -0,0 +1,7 @@
version: "3"
includes:
lib:
taskfile: ../lib/Taskfile.yml
vars:
RECEIVER: "bar"

View File

@@ -0,0 +1,7 @@
version: "3"
includes:
lib:
taskfile: ../lib/Taskfile.yml
vars:
RECEIVER: "foo"

View File

@@ -0,0 +1,9 @@
version: "3"
vars:
RECEIVER: "world"
tasks:
greet:
cmds:
- echo 'Hello {{.RECEIVER}}'