py-tyroCLI interfaces & config objects, from types
1.0.16develΣ=0 1.0.16Version of this port present on the latest quarterly branch.upstream: 1.0.17A newer version was found upstream by portscout, first on 2026-11-05.
tyro provides a lightweight, ergonomic way to build CLI interfaces and
config objects directly from Python type annotations. It wraps argparse
with a clean, type-driven API and sensible defaults, letting you turn
dataclasses, attrs classes, or Pydantic models into CLI interfaces.
Features:
- Declare CLI arguments with Python type hints and dataclasses
- Automatic --help generation from docstrings
- Shell completion for bash, zsh, fish, and PowerShell
- Nested subcommands with minimal boilerplate
- Hierarchical / modular configuration structures
NOTE: If this package has multiple flavors (see below), then use one of them instead of the name specified above. NOTE: This is a Python port. Instead of py312-tyro listed in the above command, you can pick from the names under the Packages section.
devel/py-tyro: new port
tyro is a lightweight, ergonomic way to build CLI interfaces and
config objects directly from Python type annotations. It wraps
argparse with a clean, type-driven API and sensible defaults,
letting you turn dataclasses, attrs classes, or Pydantic models
into CLI interfaces.
It provides automatic --help generation from docstrings, shell
completion for bash/zsh/fish/PowerShell, and nested subcommands
with minimal boilerplate.
Signed-off-by: Pedro Ramos <pr9000@tutamail.com>
Co-authored-by: Michael Osipov <michaelo@FreeBSD.org>
PR: 297523