亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

如何在MacOSX10.6.4上卸載Python2.7?

如何在MacOSX10.6.4上卸載Python2.7?

慕的地6264312 2019-06-15 18:29:48
如何在MacOSX10.6.4上卸載Python2.7?我想從我的MacOSX10.6.4中完全刪除Python2.7。我設法從PATH通過還原我的.bash_profile..但是我也希望刪除Python2.7安裝包安裝的所有目錄、文件、符號鏈接和條目。我從http://www.python.org/..我需要刪除哪些目錄/文件/配置文件條目?什么地方有單子嗎?
查看完整描述

3 回答

?
瀟瀟雨雨

TA貢獻1833條經驗 獲得超4個贊

如果使用PKG安裝程序安裝它,則可以:

pkgutil --pkgs

或更好:

pkgutil --pkgs | grep org.python.Python

它將輸出如下內容:

org.python.Python.PythonApplications-2.7org.python.Python.PythonDocumentation-2.7org.python.Python.PythonFramework-2.7org.
python.Python.PythonProfileChanges-2.7org.python.Python.PythonUnixTools-2.7

現在可以選擇要取消鏈接(刪除)的包。

這是取消鏈接的文檔:

 --unlink package-id             Unlinks (removes) each file referenced by package-id. WARNING: This command makes no attempt to
  perform reference counting or dependency analy-
             sis. It can easily remove files required by your system. It may include unexpected files due to package tainting.
              Use the --files command first
             to double check.

在我的示例中,您將鍵入

pkgutil --unlink org.python.Python.PythonApplications-2.7pkgutil --unlink org.python.Python.PythonDocumentation-2.7pkgutil --unlink
 org.python.Python.PythonFramework-2.7pkgutil --unlink org.python.Python.PythonProfileChanges-2.7pkgutil --unlink org.
 python.Python.PythonUnixTools-2.7

或者用一行:

pkgutil --pkgs | grep org.python.Python | xargs -L1 pkgutil -f --unlink

重要內容:-從獅子開始就不再有鏈接了(截至2014年第1季度,將包括獅子、山獅和小牛)。如果任何來看這個說明的人試著用它和獅子一起使用,應該試著用這篇文章說的話來調整它:https:/wincent.com/wiki/卸載_Packages_(.pkg_file)_on_mac_OS_X


查看完整回答
反對 回復 2019-06-15
  • 3 回答
  • 0 關注
  • 6036 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號