Nob.py
Reasonable defaults for Click CLI applications with rich logging...
... and additional goodies.
Installation
uv add nob.py
Or:
pip install nob.py
Install from GitHub
uv add git+https://github.com/ThomasByr/nob.py --branch main
or lock a specific version:
uv add git+https://github.com/ThomasByr/nob.py --tag v0.1.3
Or if you are using pip
pip install git+https://github.com/ThomasByr/nob.py@main
You may directly also use @ with a tag, for example:
pip install git+https://github.com/ThomasByr/nob.py@v0.1.3
Available extras
ipc- for inter-process communication with posix_ipc (Linux and MacOS only).
Usage
from nob import cli
@cli.cmd()
@cli.opt("--name", required=True, help="Greet someone.")
def hello(lg: cli.Logger, name: str):
lg.info("Hello %s", name)
if __name__ == "__main__":
hello()
run with:
uv run <file.py> --name "Eric Norbert"
Replace uv run with python once your environment is activated - if you don't use uv.
Contributing
Pre-requisites
-
Install uv if you haven't already (or run
uv self update):Linux Bash
curl -LsSf https://astral.sh/uv/install.sh | sh
or
wget -qO- --content-disposition https://astral.sh/uv/install.sh | sh
Windows Powershell
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
-
Install just:
With uv
uv tool install rust-just
Or if you have cargo
This way you can also install just-lsp.
cargo install --locked just just-lsp
Useful just recipes
List all available recipes
just
Sync the codebase dependencies
Without explicit --all-extras syncing, some recipes will not evaluate on optional dependencies and functionalities.
The sync recipe will also update the dependencies if possible.
just sync
Release a new version
This recipe uses release-it. You will need a working npx installation.
Install fnm with cargo
cargo install fnm --locked
fnm install --lts
fnm use --lts
just release
Metadata
Release files for nob.py 1.5.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| nob_py-1.5.1.tar.gz | 25.2 kB | Without provenance | Details for nob_py-1.5.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nob_py-1.5.1-py3-none-any.whl | Python 3 | none | any | Details for nob_py-1.5.1-py3-none-any.whl |
Total release size: 60.7 kB
Release files / nob_py-1.5.1.tar.gz
| Download URL | nob_py-1.5.1.tar.gz |
|---|---|
| Size | 25.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0dd5e03a2a668581aaf8c817dae0d5b27b8d0515557611b17c644bd4e9a5b4d3
|
|
BLAKE2b-256 checksum How to use checksums |
7d4ddaca8472ca086c933a91617b915997f77afceb85d13df3dc20a1fa414384
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.12.14 {"installer":{"name":"uv","version":"0.12.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / nob_py-1.5.1-py3-none-any.whl
| Download URL | nob_py-1.5.1-py3-none-any.whl |
|---|---|
| Size | 35.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8eece9044b6b605d16a6257534953631cd298102df53150157ab7ba51451b4d2
|
|
BLAKE2b-256 checksum How to use checksums |
7637597eb05967ff51e42bd8cdbc4b20087a1b2863123d5245f99e999e5fe77c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.12.14 {"installer":{"name":"uv","version":"0.12.14","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for nob.py 1.5.1
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.