Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Mac `zsh: command not found: psql`

I already added the path to the .bash_profile like this.

#psql
export "PATH=/Applications/Postgres.app/Contents/Versions/14/bin:$PATH"

And I successfully ran psql after I do source .bash_profile.

The problem is that when I closed the terminal and reopen it, psql doesn’t work. I have to source .bash_profile again. How can I fix it?

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

That is because you are editing .bash_profile and using zsh.

If you to fix the problem, please edit .zshrc. Or alternatively, you can edit .profile and it will work when you use both bash and zsh or any other shell that of your choice.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading