Global variables not accepting types? #2299
-
I'm not sure what behavior I'm seeing here, I'm just trying to have a top level
And then use it in a task:
This errors out with this message:
Why is this failing? |
Beta Was this translation helpful? Give feedback.
Answered by
vmaerten
Jun 16, 2025
Replies: 1 comment 2 replies
-
I think you have some space or tab issues This is working well : # https://taskfile.dev
version: '3'
vars:
deps:
- nfs-server
- csi-controller
- csi-node
tasks:
default:
cmds:
- echo {{index .deps 2}}
Note that you won't be able to access to index 3 because index start at 0. So there are 3 index: 0,1 and 2 |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
vmaerten
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think you have some space or tab issues
This is working well :
Note that you won't be able to access to index 3 because index start at 0. So there are 3 index: 0,1 and 2