Environment Variables

Each persona can have their own cli.run environment variable overridesCommon variables definition: cliEnv { MY_VAR = "webtau" PREFIX_VAR = "__" } Persona overrides personas { Alice { cliEnv.MY_VAR = "Alice!" } Bob { cliEnv.MY_VAR = "Bob!" } } Script that prints env variable value #!/bin/bash echo "hello $MY_VAR" Different value will be printed depending on the active persona Alice { cli.run('scripts/hello-env-var') { output.should == 'hello Alice!' } } Bob { cli.run('scripts/hello-env-var') { output.should == 'hello Bob!' } }