File tree Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Original file line number Diff line number Diff line change 2727 experiments (similar to ` .env ` ) (#1982 by @vmaerten ).
2828- Added new [ Getting Started docs] ( https://taskfile.dev/getting-started ) (#2086
2929 by @pd93 ).
30+ - Allow ` matrix ` to use references to other variables (#2065 , #2069 by @pd93 ).
3031
3132#### Package API
3233
Original file line number Diff line number Diff line change @@ -1412,6 +1412,27 @@ darwin/amd64
14121412darwin/arm64
14131413` ` `
14141414
1415+ You can also use references to other variables as long as they are also lists :
1416+
1417+ ` ` ` yaml
1418+ version: "3"
1419+
1420+ vars:
1421+ OS_VAR: ["windows", "linux", "darwin"]
1422+ ARCH_VAR: ["amd64", "arm64"]
1423+
1424+ tasks:
1425+ default:
1426+ cmds:
1427+ - for:
1428+ matrix:
1429+ OS:
1430+ ref: .OS_VAR
1431+ ARCH:
1432+ ref: .ARCH_VAR
1433+ cmd: echo "{{.ITEM.OS}}/{{.ITEM.ARCH}}"
1434+ ` ` `
1435+
14151436# ## Looping over your task's sources
14161437
14171438You are also able to loop over the sources of your task :
You can’t perform that action at this time.
0 commit comments