DarthSim / overmind

Process manager for Procfile-based applications and tmux
MIT License
2.82k stars 79 forks source link

Loading of ~/.overmind.env seems broken #98

Closed ianmalott closed 3 years ago

ianmalott commented 3 years ago

Per the environment section of the README, I'd expect to be able to set env vars via \~/.overmind.env for global config across projects. I've found that I can set env vars via ./.overmind.env for project-specific config. In main.go, it looks like the issue may be the expectation of shell-like expansion of "\~" to a home dir path.

https://github.com/DarthSim/overmind/blob/master/main.go#L196-L197:

    godotenv.Overload("~/.overmind.env")
    godotenv.Overload("./.overmind.env")

It doesn't look like the underlying os.Open will do that, though. Instead, I think os.UserHomeDir could do the trick. I'll submit a PR shortly.

By the way, thanks for building this clever tool. I've used foreman, heroku local, and most recently tmux to work around their shortcomings, but that has meant stepping away from the Procfile. This seems like a much more promising solution.