1.mac自帶Python2.7
2.安裝pip
easy_install pip
3.安裝MySQLdb
sudo pip install MySQL-python
(MySql重新安裝後,import MySQLdb 可能報錯" Reason: image not found",此時sudo pip uninstall ... 然後重新安裝即可 )
4.安裝pycurl
sudo pip install pycurl -i https://pypi.tuna.tsinghua.edu.cn/simple --user
不帶--user會報錯: error: could not create '/System/Library/Frameworks/Python.framework/Versions/2.7/share': Operation not permitted
待續。。