1.python下安装pip
python2或3 sudo easy_install pip
2.不同版本python下用pip安装库
mac python2或3 -m pip install
3.配置python环境命令
open ~/.bash_profile
文件配置输入:
export PATH=${PATH}:/Library/Frameworks/Python.framework/Versions/3.6/bin
alias python="/Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6"
实行:
source ~/.bash_profile