visit
zsh: command not found: python
The first thing you should check is that python is installed. You can install python from the terminal if you have brew
installed it by simply typing:
brew install python
to install it. Once python
is installed, try running python
from the terminal again. If you still face the same issue, move to step 2.
The next step is to add python
to zsh so that it will run upon typing the python
command. You can do this by running the following in terminal:
echo "alias python=/usr/bin/python3" >> ~/.zshrc
This will configure your zsh profile to run /usr/bin/python3
when python
is run. If you are still facing issues, ensure that python=$
where the $ sign should equal the path python
is installed on.
Now that you've done that, simply restart your terminal. When you open it again, your python
command should work successfully.