家酿不能正确链接python? [英] Homebrew not linking python correctly?
本文介绍了家酿不能正确链接python?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我用自制软件安装了python 2.7.13和python 3.6.2,并以如下方式更新了我的〜/.bash_profile:
I installed both python 2.7.13 and python 3.6.2 with homebrew and updated my ~/.bash_profile as such:
# Homebrew
export PATH=/usr/local/bin:$PATH
Python3链接良好.但是,哪个python"仍然会给我
Python3 was linked fine. However, "which python" would still give me
/usr/bin/python
而"python2"产生的是
while "which python2" produces
/usr/local/bin/python2
看起来自制软件将python 2安装为"python2",并且从未将"python"链接到新安装.这在安装virtualenvwrapper等时给我带来很多麻烦.
It looks like homebrew installed python 2 as "python2" and never linked "python" to the new installation. This is causing me a lot of trouble down the road when installing virtualenvwrapper etc.
顺便说一句,我也做了
brew link python
.
By the way, I also did
brew link python
.
有人知道这是为什么以及如何解决?
Anybody know why this is and how to fix it?
非常感谢!
推荐答案
查看全文