Skip to main content

clidantic

Typed Command Line Interfaces powered by Click and Pydantic.

:warning: Library in early alpha stage

test passing coverage pypi version python versions


Documentation

The first draft of documentation is available here: https://edornd.github.io/clidantic/

Installing

The safest path is to install the latest release using pip:

pip install clidantic

Optionally, you can install the latest updates through GitHub:

pip install git+https://github.com/edornd/clidantic.git

or, if that doesn't work, with multiple steps (this last step might require poetry):

git clone https://github.com/edornd/clidantic.git
cd clidantic
pip install .

Quickstart

Here's a quick example to get you started:

from typing import Optional
from pydantic import BaseModel

from clidantic import Parser


class Arguments(BaseModel):
    field_a: str
    field_b: int
    field_c: Optional[bool] = False


cli = Parser()


@cli.command()
def main(args: Arguments):
    print(args)


if __name__ == "__main__":
    cli()

Contributing

We are not quite there yet!

Metadata

Release files for clidantic 0.1.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 clidantic 0.1.0
File Size Uploaded
clidantic-0.1.0.tar.gz 11.6 kB Details

Built distribution (wheel)

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

Total release size: 23.9 kB

Release files / clidantic-0.1.0.tar.gz

Download URL clidantic-0.1.0.tar.gz
Size 11.6 kB
Tags Source
SHA-256 checksum
How to use checksums
01316a757f747475afafb84c3842f2eccff8236e49dc76f815c3ba7b7be8db32
BLAKE2b-256 checksum
How to use checksums
ca4ee4608a4432a0023b707c96085b4e2148f2126fcc416631aad24b5bef6040
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.2.0b3 CPython/3.8.10 Linux/5.4.0-121-generic

Release files / clidantic-0.1.0-py3-none-any.whl

Download URL clidantic-0.1.0-py3-none-any.whl
Size 12.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
59262183d7ab7f5fc8babe18dc047bbd26be4551c8cff20fb08706bd86f4ec28
BLAKE2b-256 checksum
How to use checksums
2a563ed816dfd4de8e59957329dcfe3c766e88e915968260f696a6ade3f322dc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.2.0b3 CPython/3.8.10 Linux/5.4.0-121-generic

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

0.0.0

2 release files

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