Skip to main content

simple and pretty tool for selecting items by keyboard in terminal

Project description

easyselect by gmanka

simple and pretty tool for selecting items by keyboard in terminal

navigation

installation^

pip install easyselect

usage^

from easyselect import Sel

yes_or_no = Sel(
    items = [
        'yes',
        'no',
    ]
)

answer = yes_or_no.choose()
print(answer)

rich styles support^

documentation

yes_or_no = Sel(
    items = [
        'yes',
        'no',
    ],
    styles = [
        'green',
        'red'
    ]
)

long items list support^

nums = Sel(
    items = list(range(50))
)
answer = nums.choose()
print(answer)

page size^

page_size arg allows to specify how much lines will be rendered on screen default value is 15

nums = Sel(
    items = list(range(50)),
    page_size = 3
)
answer = nums.choose()
print(answer)

supported buttons^

  • up, down, left, right
  • w, a, s, d
  • home, end
  • page up, page down

Project details


Download files

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

Source Distribution

easyselect-22.0.9.tar.gz (2.8 kB view hashes)

Uploaded Source

Built Distribution

easyselect-22.0.9-py3-none-any.whl (3.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page