- Want you use .env files like you do for all other tools?
- Don't want to include hacks in your project code for loading environment variables just for development?
- Don't want to use the nightmare environment variables features of IDEA?
- Want to easily be able to switch environments without losing your sanity?
- Create a user, recommend per project and store project files in under user's homedir rather than your own
- otherwise you need to add it & the original user to each others groups, and keep file permissions in mind
- In the .bashrc for the user: export $(cat /path/to/env/file | xargs)
Pro-tip: make this path a soft link to the current environment you want to use, and use a bash script for switching where the link points to - this could even be used in run configurations for switching in your IDE!