Skip to main content

About

PyPI - License PyPI - Implementation PyPI - Python Version GitHub tag (latest SemVer) PyPI wemake-python-styleguide

PyRofi wraps Rofi and helps you to build the hierarchical menus with neat navigation. You can also use te Wofi as the "backend".

Installation

Make sure that you have the Rofi or the Wofi installed. Then just python3 -m pip install --update --user pyrofi (requires Python ^3.6).

Example

#!/usr/bin/env python3

from pyrofi import run_menu

def hello_world(_):
    print('Hello World!')

def dice():
    import random
    return ['echo', random.choice('123456')]

run_menu({
    'Calculator': ['xcalc'],
    'Games': {
        'Rogue': ['rogue'],
        'Angband': ['angband']
    },
    'Calendar': ['ncal', '2019'],
    'Hello World': hello_world,
    'Dice': dice,
})

If you want to use Wofi, you will need to add menu_cmd=pyrofi.WOFI_CMD (or just menu_cmd='wofi) to the run_menu call.

More complex example you can see here and run it with python3 -m pyrofi.

Metadata

Release files for pyrofi 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyrofi 0.3.0
File Size Uploaded Provenance Actions
pyrofi-0.3.0.tar.gz 3.7 kB Without provenance Details for pyrofi-0.3.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pyrofi 0.3.0
File Interpreter ABI Platform Actions
pyrofi-0.3.0-py3-none-any.whl Python 3 none any Details for pyrofi-0.3.0-py3-none-any.whl

Total release size: 7.5 kB

Release files / pyrofi-0.3.0.tar.gz

Download URL pyrofi-0.3.0.tar.gz
Size 3.7 kB
Tags Source
SHA-256 checksum
How to use checksums
e7041f57fb833845d82b365f726b20673b3c3b89a09dc11e0cd2470beadf75e0
BLAKE2b-256 checksum
How to use checksums
c9de6434a5d059305de8f46c43721a3c88b16c4a24b85e04017790c00f9d9c15
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.10 CPython/3.6.8 Linux/4.15.0-118-generic

Release files / pyrofi-0.3.0-py3-none-any.whl

Download URL pyrofi-0.3.0-py3-none-any.whl
Size 3.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
09a99b1ad86bb56321582358d25777b666391aa7110759a3f63ee28d61a5df99
BLAKE2b-256 checksum
How to use checksums
d3fe33d651b1338b73473f49f7bea9698bb0b5c5a52f92af0a5a9a1a9f8a8233
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.0.10 CPython/3.6.8 Linux/4.15.0-118-generic

Security for pyrofi 0.3.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page