LoginSignup
18
12

More than 3 years have passed since last update.

MacでPython 2.xを消す方法。

Last updated at Posted at 2016-09-05

始めに。。

こんにちは。Dreamwalkerです。
みんなPython使ってますか?

最近、沢山のプログラマーから愛されているランゲージですね。
私はPytion2.7バージョンを使っているんですが、3.xバージョンにアップグレードしたかったです。

問題は3.xバージョンをインストールしても、私の彼女MACはまだ2.xバージョンを使ってるんです。悲しいですね。。

2.xバージョンをMACで消す方法を簡単に紹介したいと思います。 :metal:

インストール

Pythonホーム・ページからダウンロードできますが、
私はhomebrew使ってインストールしました。

Homebrewインストール方法。

まず、Terminal開けます。

git
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

[homebrew] http://brew.sh/

私はインストールしましたから、下のようになります。

Screen Shot 2016-09-05 at 11.56.23 AM.png

Pythonインストール方法。

terminal開けます。

brew
brew search python

Phytion2.7.x インストール

brew
brew install python

Phytion3.x インストール

brew
brew install python3

doctor〜!

brew
brew doctor

Python3インストール

Python2.x アンインストール

python経路。

which python

framework アンインストール。

sudo rm -rf /Library/Frameworks/Python.framework/Versions/2.7

Applicationからアンインストール。

sudo rm -rf "/Applications/Python 2.7"

終わりに

Macの中で基本pythonがあります。
あんまりアンインストールお勧めしたくないですね。

Terminalでpython3を使って3.x バージョン使ったり
IDLE使ったりする方がいいと思います。

読みいただきありがとうございました
次のPostで会いましょう!

Dreamwalker。

18
12
2

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
18
12