Tag Archives: eclipse

Python development in eclipse

Vim is a great text editor with a lot of useful functionality, and very powerful, however sometimes we might want to use another tools from programming such an IDE (Integrated Development Environment), and in this field one of the most popular (probably the most), is the well-known eclipse editor. Luckily, there is a very popular tool (which I recommend) to develop in python by using eclipse: this is PyDev (http://pydev.org/).

Pydev is installed as a plug-in for eclipse, so we need to execute the eclipse environment (as root users or admins because it requires such privileges). For example, eclipse could be started through the following command:

$sudo /usr/local/eclipse/eclipse
Where /usr/local/eclipse/ is the absolute path on which eclipse is installed.
After starting the program, we can go to help | eclipse marketplace. Once there, we can type the name of the plugin (Pydev) to start the installation.This installation follows the normal process, which involves selecting the package, accepting the licence and wait until downloads and installs.

When the installation is complete we still need to perform another step for linking the python build to the environment. This time is necessary to go window | preferences | pydev | Interpreter – Python | new and once there indicate the path of the python file, which should be something similar to :

/usr/bin/python2.7

This can be easily checked by the command:
$whereis python

After that we can start eclipse again, and use it normally. If everything is ok, in the menu options, you should be able to create a new python project, on file | new | project | pydev | pydev project.

As we know eclipse is a great option for developing software, and it is also useful to keep in mind another tool which can be used, despite the fact that vim is an excellent editor, it would not be bad to have another tool in the development toolkit.

 

Leave a comment

Filed under Architecture