Read–Eval–Print Loop Interpreter
Project description
🐟 Read–Eval–Print Loop Interpreter (REPLI)
This is a Python package for building Read–Eval–Print Loop (REPL) applications.
Features:
- Breadcrumbs
- Interface panel
- Pagination
────────────────────────────────────────────────────────────────
home
────────────────────────────────────────────────────────────────
╭─ commands ───────────────────────────────────────────────────╮
│ 1 print hello world │
│ 2 do something │
╰──────────────────────────────────────────────────────────────╯
╭─ builtins ───────────────────────────────────────────────────╮
│ e exit │
│ q previous page │
╰──────────────────────────────────────────────────────────────╯
> _
Install
Pip:
pip install repli
Poetry:
poetry add repli
Usage
page = Page(name='0', description='home')
@page.command(type=NativeFunction, name='1', description='print hello world')
def command_1():
print('hello world')
@page.command(type=Subprocess, name='2', description='print something else')
def command_2():
return 'echo something else'
interpreter = Interpreter(page=page)
interpreter.loop()
See example.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
repli-0.1.7.tar.gz
(7.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
repli-0.1.7-py3-none-any.whl
(9.9 kB
view details)
File details
Details for the file repli-0.1.7.tar.gz.
File metadata
- Download URL: repli-0.1.7.tar.gz
- Upload date:
- Size: 7.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8ed099b2c1f9ecdf4b4efcd3eb9991e113bea0e6f59a9d0ca8418ca9c8f4da9a
|
|
| MD5 |
e52d3664dadc377350545ecd5e03c7e6
|
|
| BLAKE2b-256 |
b4f33604d8746c0ffe2dcc83c68d379a4b7bfeaa9271190cf1207c0d43272d90
|
File details
Details for the file repli-0.1.7-py3-none-any.whl.
File metadata
- Download URL: repli-0.1.7-py3-none-any.whl
- Upload date:
- Size: 9.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.21
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
55cfb53a67dce72e57e776e71435089d3db57b0eb950e67c41a9775083d73f77
|
|
| MD5 |
bde4588be70a69d28fbb057f16c71396
|
|
| BLAKE2b-256 |
f4cc31daefd0e4fe6eba0524577594e5e0263286ff7346ee9a4f33fecc7475e8
|