GAM install doesn't install in ZSH (or other shells)
Full steps to reproduce the issue:
- Install GAM as per wiki
- Restart ZSH
Expected outcome (what are you trying to do?): GAM command will be available
Actual outcome (what errors or bad behavior do you see instead?): GAM command is not available
The appears to append gam() { "/home/dmills/bin/gam/gam" "$@" ; } to the .bashrc file to load the gam command. However zsh and other popular shells don't use .bashrc file. GAM should check what shell is running and append it in the appropriate file for at least common shell options.
Yes this is true, I'm having the same issue after installing macOS Catalina which uses zsh as the default shell
I have the same issue on macOS Catalina - any solution how to make the commands working ? thanks
Use bash? The forum is probably a better place for this discussion.
Start terminal echo 'alias gam="~/bin/gam/gam"' >> .profile source .profile gam version
Start terminal echo 'alias gam="~/bin/gam/gam"' >> .profile source .profile gam version
yes, it helps! thanks!
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
As far as I'm aware this is still an issue. More so with MacOS now defaulting to zsh instead of bash. Workarounds are nice, and I used one myself. But this should be solved by the package.
Thanks @taers232c! Totally helped :)
As far as I'm aware this is still an issue. More so with MacOS now defaulting to zsh instead of bash. Workarounds are nice, and I used one myself. But this should be solved by the package.
So I have been doing the commands that @taers232c posted which would work until terminal was restarted, and then I would need to redo those steps. What I figured out that ~/.zshrc does not exist by default and doing those commands would only write them to either to the session or to a temp file that was purged when terminal restarted. Creating .zshrc using touch ~/.zshrc and then adding alias gam="~/bin/gam/gam" to it using nano or whatever you want solved this problem.
As far as I'm aware this is still an issue. More so with MacOS now defaulting to zsh instead of bash. Workarounds are nice, and I used one myself. But this should be solved by the package.
So I have been doing the commands that @taers232c posted which would work until terminal was restarted, and then I would need to redo those steps. What I figured out that ~/.zshrc does not exist by default and doing those commands would only write them to either to the session or to a temp file that was purged when terminal restarted. Creating .zshrc using
touch ~/.zshrcand then addingalias gam="~/bin/gam/gam"to it using nano or whatever you want solved this problem.
I have a working .zshrc, I filed this bug because others probably have similar issues, and especially with MacOS switching to zsh it is probably going to come up a lot more.
Gam install on zsh still not working after change https://github.com/jay0lee/GAM/pull/1164
Jacob,
The change happened after 5.06 was released.
Ross
On Apr 23, 2020, at 7:11 AM, Jacob [email protected] wrote:
Gam install on zsh still not working after change #1164 https://github.com/jay0lee/GAM/pull/1164 — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/jay0lee/GAM/issues/940#issuecomment-618417079, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCTYL3ODFIEZ62FAJYI343ROBD75ANCNFSM4HQFGYZQ.
Jacob,
Are you installing GAM on lots of computers? Once you've set the GAM alias on a computer you're good to go.
Ross
On Apr 23, 2020, at 7:11 AM, Jacob [email protected] wrote:
Gam install on zsh still not working after change #1164 https://github.com/jay0lee/GAM/pull/1164 — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/jay0lee/GAM/issues/940#issuecomment-618417079, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCTYL3ODFIEZ62FAJYI343ROBD75ANCNFSM4HQFGYZQ.
It worked now. Not sure what I did different to make it work. I had the alias set.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
Just installed GAM and had this issue when starting up Terminal...
Last login: Fri Sep 18 13:00:55 on ttys000
/Users/sean/.zshrc:104: defining function based on alias `gam'
/Users/sean/.zshrc:104: parse error near `()'
➜ ~
Modified .zshrc to the below resolved it...
function gam() { "/Users/USERNAME/bin/gam/gam" "$@" ; }
Just forked the repo and submitted a fix. https://github.com/jay0lee/GAM/pull/1245
This is still a problem out of the box on MacOS using zsh. 😔
The workaround appears to be working.