just icon indicating copy to clipboard operation
just copied to clipboard

just evaluate does not work with modules

Open bluefing opened this issue 8 months ago • 3 comments

just --evaluate does not work with namepath

Given a root justfile Justfile with variable var_root and a module file module.just with variable var_module

just --evaluate -f Justfile var_root returns the value of var_root just --evaluate -f Justfile module::var_module returns an error just --evaluate -f foo.just var_module returns the value of var_foo

The documentation suggests --evaluate should return all variables.

Also, the dump provides a namepath for module recipes but there is no equivalent for variables, is there a reason for that.

I think the same issue applies to --variables i.e. module variables are not returned.

For context, I'm leveraging --evaluate in my tests to retrieve values to --dry-run evaluate, to ensure module recipes can be resolved - that is, to test that in-body just invocation of submodule recipes are resolvable.

I've submitted this from my phone, I'll provide a better description with minimal example when I'm back at my machine.

bluefing avatar Mar 30 '26 19:03 bluefing

Nope, no reason, these just haven't been updated to support modules.

casey avatar Mar 30 '26 19:03 casey

Done in #3219.

casey avatar Mar 31 '26 00:03 casey

Thanks!

bluefing avatar Mar 31 '26 07:03 bluefing