Skip to content

Support interpolation including parameterized goal params  #153

@xonixx

Description

@xonixx

We need to be able to do this:

@define H 'hello'

@goal g
@depends_on pg @args 'world'

@goal pg @params W
@depends_on pg1 @args "$H $W" # now doesn't work, because here W is not interpolated properly, thus is empty

@goal pg1 @params V
  echo "$V"

So this outputs hello instead of the desired hello world.

This happens because we apply interpolation as we parse, but parameterized goals (PG) processing happens at the end, after all lines parsed.

Thus the solution would be to defer those @depends_on pg1 @args "$H $W" re-parsing by moving it into the PG instantiation logic.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions