ptpython

Advanced Python REPL with syntax highlighting and autocompletion

brewmacoslinux
Try with needOr install directly
Source

About

Advanced Python REPL

Commands

ptpython

Examples

Start an interactive Python session with enhanced features$ ptpython
Run a Python script and drop into ptpython REPL after execution$ ptpython -i script.py
Execute Python code with ptpython and exit$ ptpython -c 'print("Hello World")'