Chinaunix首页 | 论坛 | 博客
  • 博客访问: 160283
  • 博文数量: 27
  • 博客积分: 2179
  • 博客等级: 大尉
  • 技术积分: 335
  • 用 户 组: 普通用户
  • 注册时间: 2008-03-21 12:53
文章分类

全部博文(27)

文章存档

2012年(1)

2010年(9)

2009年(7)

2008年(10)

我的朋友

分类: LINUX

2009-07-05 13:58:56

刚刚接触python,写的代码的时候都是用vi,感觉效率不高,就google一下,发现有很多python的IDE,很多人用的是elclips的pydev这个插件。下面我就安装一下它:
1、下载org.python.pydev.feature-1.4.6.2788-sources.zip
2、解压
[yorks@localhost Software]$ mkdir pydev
[yorks@localhost Software]$ cd pydev/
[yorks@localhost pydev]$ ls
org.python.pydev.feature-1.4.6.2788-sources.zip
[yorks@localhost pydev]$ unzip org.python.pydev.feature-1.4.6.2788-sources.zip
features  org.python.pydev.feature-1.4.6.2788-sources.zip  plugins
3、查看安装的eclips的plugins和features目录在哪里。
[yorks@localhost pydev]$ whereis eclipse
eclipse: /usr/share/eclipse
[yorks@localhost pydev]$ ls -l /usr/share/eclipse/
总计 416
drwxr-sr-x  2 root root   4096 06-29 15:03 about_files
-rw-r--r--  1 root root  13852 2008-09-23 about.html
-rw-r--r--  1 root root  39292 2008-09-23 artifacts.xml
drwxr-sr-x  5 root root   4096 06-29 15:03 configuration
drwxr-sr-x  2 root root   4096 2008-09-23 dropins
-rwxr-xr-x  1 root root  19475 2008-10-31 eclipse
-rw-r--r--  1 root root    113 2008-09-23 eclipse.ini
-rw-r--r--  1 root root  16536 2008-09-23 epl-v10.html
drwxr-sr-x 20 root root   4096 07-05 13:24 features
-rwxr-xr-x  1 root root 263000 2008-10-31 libcairo-swt.so
-rw-r--r--  1 root root   6506 2008-09-23 notice.html
drwxr-sr-x  5 root root   4096 06-29 15:03 p2
drwxr-sr-x 22 root root  20480 07-05 13:25 plugins
drwxr-sr-x  2 root root   4096 06-29 15:04 readme
通过查看知道features和plugins的目录在/usr/share/eclipse目录下。
4、将pydev的features和plugins目录下的所有东西mv到/usr/share/eclipse/对应的目录下。
[yorks@localhost pydev]$ mv features/* /usr/share/eclipse/features/
[yorks@localhost pydev]$ mv plugins/* /usr/share/eclipse/plugins/
5、启动eclipse,设置pydev的环境。
Window => preferences => 点击左边的pydev => 单击interpreter-Python
=> 点击右边的new =>填好name(我这里填python)和executable路径(我这里填写我的python执行路径:/usr/bin/python)

===================================完毕=================================
注意:在第5步中,一定要设置好。如果没有设置好,会在你新建python工程的时候出现Project interpreter not specified错误提示。


阅读(2649) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~