Skip to main content

Arbitrium - The Easy Menu System For Python

Project description

# Arbitrium - The Easy Menu System For Python

## Install
`pip install arbitrium`

## Usage
```
from arbitrium import menu
from os import exit

@menu(["Option One", "Option Two", "Final Option"])
def choice_handler(choice):
if choice == 1:
# Option One Selected
pass
if choice == 2:
# Option Two Selected
pass
if choice == 3:
# Final Option Selected
exit(1)

# Calling the choice handler will also print the menu
choice_handler()
```
Will produce:
```
1) Option One
2) Option Two
99) Final Option
Please enter your choice:
```

**NOTE: Final Option will always be 99. It will run the choice handler once and then exit the choice handler function.**

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for arbitrium, version 1.1.1
Filename, size File type Python version Upload date Hashes
Filename, size arbitrium-1.1.1.tar.gz (2.3 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page