Very simple cli framework for the very lazy
Reason this release was yanked:
Minz is now baci (https://pypi.org/project/baci/)
Project description
WIP!! This is incomplete/theoretical examples!
minz - very simple cli framework (for the very lazy)
Got No time to learn and download a huge framework just to make some simple clis? Yeah me neither I got a board game meetup to get to after this!
Why not just write a bunch of vanilla python functions and let minz deal with the weird linux stuff?!
# this can already be a cli command
def say_hello():
# docstring adds a description to --help options
"""
Prints hello to the screen
"""
print("hello lazy!")
if __name__ == '__main__':
minz = Minz()
minz.register(say_hello)
minz.run()
$ python cli.py say-hello
hello lazy!
But generally you would add an entrypoint to your cli that discovers all functions
from minz import Minz
minz.autorun(dir="./commands")
All non-private defined functions in commands/ will be registerd in the cli
Prefix with a _
to be ignored. That's the only way.
philosophies
Be a strong, independent package who don't need no pypi
Dependencies means vulnerabilities, which means frequent patching and updating. WHO GOT TIME FOR DAT?
Write it all in-house.
Update like it's moving apartments
Would you move to a new studio bedroom every month?
Command line syntax hasn't changed for decades, what's there to update?
Make it feature complete and reliable.
The only exceptions are if there's a bug. Just like in your apartment, you would make the effort to get rid of bugs.
There's no zen here, bub!
We don't follow zen of python. Zen is nice but we live in the real world, ya dig? No bad-ass mf got time for explicitly stating everything. So just learn the conventions here once and save big on keystrokes!
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
Built Distribution
File details
Details for the file minz-0.0.1.tar.gz
.
File metadata
- Download URL: minz-0.0.1.tar.gz
- Upload date:
- Size: 4.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 35e8aed8551c62079a3a3843cb4d0177a2876aee7016059c5b86d74aa5addf4a |
|
MD5 | e0b64b724a6b6d7eb111c36f77488c5f |
|
BLAKE2b-256 | b63cb94593e4287a0ec7a9263487fcc445d224b6ecdf40dae7d60cfab5b91496 |
File details
Details for the file minz-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: minz-0.0.1-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.11.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 00ac3f01e0e16296344c0ba3c1c51dc26aa1dbc01e1a8e868784d9a5cc650a14 |
|
MD5 | b91d87e110f2186a44aadb09001e3227 |
|
BLAKE2b-256 | 6035f65a32f89888a34bd5ae886f1f92e8036b258c629aaf23e64322979b00e1 |