-
-
Notifications
You must be signed in to change notification settings - Fork 775
Closed
Description
- Task version: 3.36.0
- Operating system: Linux (probably others)
- Experiments enabled: none
We need 2 task files (see https://taskfile.dev/usage/#vars-of-included-taskfiles):
Taskfile.yml:
version: '3'
includes:
subA:
taskfile: DockerBuild.yml
subB:
taskfile: DockerBuild.yml
vars:
DOCKER_IMAGE: imageOfB
tasks:
default:
cmds:
- task: subA:show # Uses the default value.
- task: subB:show # Used to be `imageOfB`. Now is `default_image`.and DockerBuild.yml:
version: '3'
vars:
DOCKER_IMAGE: default_image
tasks:
show:
cmds:
- echo "DOCKER_IMAGE = {{.DOCKER_IMAGE}}"Since version 3.36.0 I get:
$ task
task: [subA:show] echo "DOCKER_IMAGE = default_image"
DOCKER_IMAGE = default_image
task: [subB:show] echo "DOCKER_IMAGE = default_image"
DOCKER_IMAGE = default_imageIn previous versions it was possible to override variables when including taskfiles changing the second case to:
$ task
task: [subA:show] echo "DOCKER_IMAGE = default_image"
DOCKER_IMAGE = default_image
task: [subB:show] echo "DOCKER_IMAGE = imageOfB"
DOCKER_IMAGE = imageOfBIs this an intended change? And if yes, how would we implement something like that instead?
Metadata
Metadata
Assignees
Labels
No labels