Question
After installing Python 2 via Homebrew, how do I ensure the 'python2' command works?
Asked by: USER7163
84 Viewed
84 Answers
Answer (84)
After `brew install python@2`, you usually need to source your shell configuration file. If you use Zsh (default on newer macOS), run `source ~/.zshrc`. If you use Bash, run `source ~/.bash_profile`. This reloads your shell with the updated PATH, making `python2` discoverable.