MAC Leopard安裝easygui方法介紹

來源:互聯網
上載者:User

最近在看一本《與孩子一起學編程》Warren Sande Carter Sande 。

此書用的python是2.5版本,我在leopard上安裝的是3.5版本,當需要使用easygui時依照書中所說方式下載http://easygui.sourceforge.net

發現不能如書中所說將easygui.py拷貝到python目錄即可,需要重新安裝一下。

 

     Installing EasyGui
  • Download the archive file of your choice
  • Unpack the archive file into a temporary directory
  • In the temporary directory, locate the file called setup.py
  • In a console window, at the command prompt, enter the command:
python  setup.py  install

If you're using some form of Linux (e.g. Ubuntu) you may need to use the sudo command

sudo python  setup.py  install

or something (depending on your version of Python) like this

sudo  /usr/bin/python2.6  setup.py  install
網站如此介紹,唯獨缺少leopard如何安裝,下面我說一下:
1、首先通過命令列進入到easygui.py那個目錄
2、然後在easygui.py目錄下執行 
 python3.5   setup.py install
(你應是管理員權限,python3.5代表你目前安裝的python版本)
3、最後再執行
 python3.5  -m  easygui
即可。
檢驗一下是否安裝成功,在IDLE下 執行
>>>import easygui
不出問題即可,同理類似安裝可同理進行。
祝玩的開心!

 

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.