Comment by aesbetic

4 days ago

Yea that’s not gonna work, you have to export it for it to become part of your shell’s environment and be passed down to subprocesses.

You could however wrap the export variable and codex command in a script and just call that. This way the variable would only be part of that script’s environment.