Skip to content

Instantly share code, notes, and snippets.

@aviiciii
Last active July 12, 2023 17:50
Show Gist options
  • Select an option

  • Save aviiciii/48a9c1fdb935958a60928a35e0b6cf91 to your computer and use it in GitHub Desktop.

Select an option

Save aviiciii/48a9c1fdb935958a60928a35e0b6cf91 to your computer and use it in GitHub Desktop.
Use 'py' instead of 'python3' in macOS
# open in terminal
$ nano ~/.zshrc
# this open a file in nano editor
# add the following line in the editor
alias py=python
or
alias py=python3
# Make sure to save (write out) by pressing Ctrl+O then Enter. Then press Ctrl+X and Enter to exit nano.
# Close the terminal and open
# Check if alised using
$ py --version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment