Configuring Python Ide--emacs under Linux

Source: Internet
Author: User

工欲善其事, its prerequisite. Python as a high-level language, because its introduction, flexibility has been more and more programmers favor. After trying out a lot of Ides, I finally found my beloved. Less nonsense, let's start by saying how to install Emacs under Linux.

1. Install Emacs

sudo apt-get install Emacs24

Next, you'll install Pip, a handy Python package management tool for installing Python modules.

sudo apt-get install python-pip #Python2  sudo apt-get install Python3-pip #Python3  

Then install the elpy, rope, Jedi module with PIP

sudo pip install elpy rope jedi #Python2  sudo pip3 install elpy rope_py3k Jedi #Python3  

Enter Emacs & To open the IDE, as follows:

2. Configure Emacs

Create a new file Init.el in ~/.emacs.d, write the following to initialize the Package.el and add the plug-in Source:

 (Require   archives   "  (" GNU ". "Http://elpa.gnu.org/packages/")  (  Marmalade  .  " http://marmalade-repo.org/packages/  " ) (  melp A   ".  " http://melpa.milkbox.net/packages/  " -initialize) 

To restart Emacs, use m-x package-install [Enter] elpy [Enter] to install (enter is the return key). You can also use the command m-x list-packages to get a list of plugins, using c-s to find elpy to install.

Next, add the following in the Init.el file:

;; Configuration of the Python IDE  ; https:///github.com/jorgenschaefer/elpy  ' elpy nil t)   (elpy-enable)  

Restart Emacs. At this point the Python IDE is complete. Create a new Python file (c-x c-f, enter the file name), start your Python tour, you will find automatic completion, syntax error detection, syntax template display and other functions are already there.

Emacs can be implemented with features like Eclipse and other Ides. Many excellent Emacs plug-ins can be installed directly through the M-x List-packages, a simple configuration file, you can put the Python IDE configuration!

Configuring Python Ide--emacs under Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.