RFE: environment should be also confgigurable from CMD line
as https://tmt.readthedocs.io/en/stable/spec/plans.html#environment is possible to add more env variables to test execution and it is on same level as other steps. I know that it is not step, but I expect that also cmd line would have also possible to do something like:
tmt run -a environment -var "KEY=value" ...
closing as there exists --environment for tmt run
As there exists command line opts, probably it would be nice to improve it inside doc, I can imagine that in FMF specification, for items like https://tmt.readthedocs.io/en/stable/spec/plans.html#environment could be mentioned how to override/append this via command line.
as I searched for this option in tmt run execute/prepare --help where I expect this to be defined. probably define it inside run level is fine, but does that means that this ENV var is passed also e.g. when I've use tmt run -e "VAR=hello" -a prepare -s echo $VAR
As there exists command line opts, probably it would be nice to improve it inside doc, I can imagine that in FMF specification, for items like https://tmt.readthedocs.io/en/stable/spec/plans.html#environment could be mentioned how to override/append this via command line.
This part should be already covered in the docs:
# Variables from the command line
tmt run --environment X=1 --environment Y=2
tmt run --environment "X=1 Y=2"
as I searched for this option in
tmt run execute/prepare --helpwhere I expect this to be defined. probably define it inside run level is fine, but does that means that this ENV var is passed also e.g. when I've usetmt run -e "VAR=hello" -a prepare -s echo $VAR
Yeah, I believe the environment area would definitely deserve a separate section in the Guide, now that the environment key has been implemented under the provision key the precedence is even a bit more complicated. Let's clarify that in a new Environment section.
Added to the backlog with should priority.