Mac 删除/卸载 自己安装的python |
您所在的位置:网站首页 › 林美什么好听 › Mac 删除/卸载 自己安装的python |
官网pkg安装的python版本 第一步:删除框架 sudo rm -rf /Library/Frameworks/Python.framework/Versions/2.7第二步:删除应用目录 sudo rm -rf "/Applications/Python 2.7"第三步:删除指向python的链接 cd /usr/local/bin/ ls -l /usr/local/bin | grep '/Library/Frameworks/Python.framework/Versions/2.7' # 查看链接 brew prune # 清除链接和目录清除后可再次查看链接,会发现链接已清除 附图: ![]() ![]() ![]() 可参考: https://stackoverflow.com/questions/22774529/what-is-the-safest-way-to-removing-python-framework-files-that-are-located-in-di homebrew安装的python版本命令卸载: brew uninstall python最后,推荐使用homebrew安装python: 1. 可以指定python版本 2. 安装卸载都方便,避免对系统自带的python版本误操作 3. 安装某些软件时会连带安装python包,如果系统中已安装该版本包,但不是用brew安装的,就会引起冲突,导致安装失败 Homebrew only supports building against the System-provided Python or a brewed Python. In particular, Pythons installed to /Library can interfere with other software installs.homebrew只支持编译系统默认和brew安装的python版本 来源 python安装路径 系统默认 /System/Library/Frameworks/Python.framework/Versions/2.7 brew安装 /usr/local/Cellar 官网pkg安装 /Library/Frameworks/Python.framework/Versions/2.7 |
今日新闻 |
点击排行 |
|
推荐新闻 |
图片新闻 |
|
专题文章 |
CopyRight 2018-2019 实验室设备网 版权所有 win10的实时保护怎么永久关闭 |