LPGhatguy / aftman

Aftman, the prodigal sequel to Foreman
MIT License
157 stars 16 forks source link

Create ~/.zshenv if SHELL=zsh #28

Closed LPGhatguy closed 2 years ago

LPGhatguy commented 2 years ago

Fixes #23.

This one is a bit tricky to test. I don't have a macOS machine, so I can't test it myself. Any help validating this change would be hugely appreciated!

To test:

konstantinepapakonstantinou commented 2 years ago

This works on my machine. For what it's worth, I would add onto the install documentation to let people know they need to run the Aftman setup with sudo. Otherwise, Aftman is unable to actually change your .zshenv- at least, this was the case for me.

LPGhatguy commented 2 years ago

Thanks for testing this!

I don't think users should need to run aftman self-install with sudo. That's strange. Is it normal for .zshenv to be owned by root or some other user?

konstantinepapakonstantinou commented 2 years ago

I am not sure what would specifically be causing the issue. The environment files are owned by me as the user and I have r/w access. It could have something to do with macOS itself- on a number of occasions, I have found myself needing to run things like npm or cargo with sudo. Maybe it's just an os-level quirk.