I have had at least 1 human approach me and inquire upon optional loading of .env's into a given environment.
Reading through the Tmux documentation (by that, I mean the man page) the following text is stated to be possible:
If -E is used, the update-environment option will not be applied. -e takes the form ‘VARIABLE=value’ and sets an environment variable for the newly created session; it may be specified multiple times.
I have had at least 1 human approach me and inquire upon optional loading of .env's into a given environment.
Reading through the Tmux documentation (by that, I mean the man page) the following text is stated to be possible:
http://man.openbsd.org/OpenBSD-current/man1/tmux.1#GLOBAL_AND_SESSION_ENVIRONMENT
We are creating sessions as it is to inject your commands into, thus it should be rather possible to load an env.
We have the project
Zdotenv
which exposes the parser for loading a .env (instead of loading the .env directly into thestd.process.EnvMap
.Project: https://github.com/BitlyTwiser/zdotenv
Import the parser and utilize this to parse and inject the .env values into the tmux session.