Windows构建python开发环境

1、安装python
下载:
https://www.python.org/downloads/windows/

2、安装vc express
http://www.visualstudio.com/zh-cn/downloads/download-visual-studio-vs#DownloadFamilies_4

3、安装easy_install工具
下载ez_setup.py脚本:
https://pypi.python.org/pypi/setuptools#windows-7-or-graphical-install

然后执行python ez_setup.py

报错:
UnicodeDecodeError: 'ascii' codec can't decode byte 0xb0 in position

修改python安装目录下的lib子目录:mimetypes.py(文件位置如:D:\Program Files\Python 2.7\Lib)
    
    
    
    
  1. import sys
  2. default_encoding = 'gbk'
  3. if sys.getdefaultencoding() != default_encoding:
  4.     reload(sys)
  5.     sys.setdefaultencoding(default_encoding)

修改环境变量:
PATH加上python安装目录的Scripts目录(如: D:\Program Files\Python 2.7\ )

4、安装ipython交互工具
easy_install ipython

5、安装wingide
http://wingide.com/downloads/wingide





来自为知笔记(Wiz)


你可能感兴趣的:(Windows构建python开发环境)