I bought a MacMini (M1), so a memo until I Hello World
python.
Until you pass the Path
Read Quick Start
--Install XCode --Install from the App Store of the native app --Check if you have agreed to the command line and license
$ xcode-select --install
$ sudo xcodebuild -license
--Install MacPorts --Go to HP and download (links by OS version at the top of QuickStart) --Pass through Path
~/zshrc
export PATH=/opt/local/bin:/opt/local/sbin/:$PATH
export MANPATH=/opt/local/man:$MANPATH
--Install python
sudo port install python38
--Set to run with python
(It is recommended to set either of the following when the port is completed)sudo port select --set python python38
sudo port select --set python3 python38
python3 --version
――In addition, add pip
sudo port install pip-38
sudo port select --set pip pip-38
pip --version
$ python3
>>> print("Hello World")
Recommended Posts