Bpython powerful Python shell

Source: Internet
Author: User
Python is a very useful and popular interpretive programming language, one of the advantages of which is the ability to use its interactive shell for exploratory programming. You can try typing in some code and get feedback from the interpreter immediately without having to write a script specifically. But Python's own shell has some limitations, such as the inability to auto-complete, the inability to highlight syntax, and so on.

Fortunately, the powerful Python extended the default shell and developed many beautiful python shells. Each one provides an excellent interactive Python experience. Today I would like to introduce one of the more excellent-bpython.

Bpython Introduction

Bpython is a nice Python interpreter interface, the developer's goal is to provide users with all the built-in features, much like the current IDE (integrated development environment), but these features are encapsulated in a simple, lightweight package, can be run in a terminal window.

Bpython does not seek to create anything new or groundbreaking. Instead, it gathers a few simple ideas that focus on practicality and operability.

How to Install

The latest version of Bpython is 0.15. There are four types of mounting options:

    • Download the latest version of tarball:http://bpython-interpreter.org/releases/
    • Clone Bpython git repository: Git clone https://github.com/bpython/bpython/
    • Install via PIP: Pip install Bpython
    • Package Manager via system: Apt-get install Bpython

If you want Bpython to work properly, you will also need to install the following dependency packages:

Pygments requests Curtsies >= 0.1.18,< 0.2 greenlet urwid (for Bpython-urwid only)

Specific functions

Features are very rich, including:

    • Built-in syntax highlighting – use Pygments to lay out the code you've knocked out and make a reasonable color match
    • Show auto-complete suggestions based on your behavior
    • List the desired parameters for any Python function – you can display a list of parameters for any function you call
    • The "Rewind" function will bring up the last line of code in memory and execute it again.
    • You can send the code you entered to Pastebin
    • You can save the code you entered to a file
    • Auto Indent
    • Support for Python 3

A similar Python shell

In addition to Bpython, there are three similar python shells such as Ipython, Ptpython, and Dreampie.

Know what is Bpython, its installation method, the function of it, I hope you can in-depth understanding.

  • Related Article

    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.