Or at least the part of it, that makes sense.
More specifically I have some environment variables, that have been exported by running a script, to create an adequate environment for the task at hand. When I run tmux these variables are nowhere to be seen, neither in the global or the session environment. Of course I can run this script again but ...
I'd be satisfied if I could specify the particular vars in my .tmux.conf
file however:
set-environment VAR $VAR
Does not do what I'd expect.
Thanks in advance :)
Ah, I think I know why.
When starting a second session of tmux, say in another terminal, it copies the environment from the first one. The first one pretty much takes the current environment of the calling shell and adds some tmuxiness to it.
My current workaround is just stopping and starting my tmux sessions when i need to change environment.