Variadic Args
{@} forwards leftover recipe CLI args to the recipe cmd.
[recipes.test]
cmd = 'go test "{pkg}" {@}'
[recipes.test.arguments.pkg]
type = "rel_path"
position = 1
required = true
values = "@go-packages"
Run it with:
shadowtree test ./internal/recipe -run=TestResolve -count=1
The typed positional value supplies {pkg}. The leftover flags are spliced at
{@} as separate shell-quoted words.
Rules
{@}is supported only incmd.- In shell command strings, it must occupy a whole shell word.
- It is not available in
pre,post, orsync_out. - For typed recipes, positional values and known
key=valuevalues are consumed by typed arguments and excluded from{@}. - Unknown identifier
key=valuetokens remain errors. - Command flags such as
-run=TestNamepass through.
Literal Pass-Through
Use -- after typed recipe arguments to pass the following argv literally to
{@}, including option values that contain =:
shadowtree test pkg=./internal/recipe -- --flag NAME=value