【发布时间】:2014-12-18 00:58:11
【问题描述】:
我刚刚升级到 OSX Yosemite。我正在运行brew doctor,它生成的无数警告中包括:
Warning: /usr/local/share/python is not needed in PATH.
Formerly homebrew put Python scripts you installed via `pip` or `pip3`
(or `easy_install`) into that directory above but now it can be removed
from your PATH variable.
Python scripts will now install into /usr/local/bin.
You can delete anything, except 'Extras', from the /usr/local/share/python
(and /usr/local/share/python3) dir and install affected Python packages
anew with `pip install --upgrade`.
我到处都仔细查看过,我找不到将 /usr/local/share/python 添加到我的路径的内容。我的 .bash_profile 没有提到 python。 /private/etc/paths.d 仅包含一个名为“git”的文件。我确实在 /private/etc/paths 中找到了 /usr/local/share/python 的实例,但我删除了它,但是当我在那之后启动一个新终端并重新运行 brew doctor 时,我仍然收到警告。谁能建议我如何阻止这种情况?快把我逼疯了!
【问题讨论】:
-
...人们仍然问我为什么我更喜欢 macports 而不是 brew(优胜美地升级后对我来说没有问题):P
-
如果您有一段时间没有升级 brew,这可能是一种症状(它甚至在错误消息中说明了这一点)。以前 brew 使用
/usr/local/share/python。 FWIW 我在升级时没有遇到这样的警告(但这可能是因为我非常保护我的 PATH)。
标签: python macos homebrew path-variables