Skip to main content

🌈 Extra colorization and configuration file for Click.

Project description

Click Extra

Last release Python versions Unittests status Coverage status

What is Click Extra?

click-extra is a collection of helpers and utilities for Click, the Python CLI framework.

It provides boilerplate code and good defaults, as weel as some workarounds and patches that have not reached upstream yet (or are unlikely to).

Used in

Installation

Install click-extra with pip:

$ pip install click-extra

Features

  • TOML configuration file loader
  • Colorization of help screens
  • --color/--no-color option flag
  • Colored --version option
  • Colored --verbosity option and logs
  • --time/--no-time flag to measure duration of command execution
  • Platform recognition utilities
  • New conditional markers for pytest:
    • @skip_linux, @skip_macos and @skip_windows
    • @unless_linux, @unless_macos and @unless_windows
    • @destructive and @non_destructive

TOML configuration file

Allows a CLI to read defaults options from a configuration file.

Here is a sample:

# My default configuration file.

[my_cli]
verbosity = "DEBUG"
manager = ["brew", "cask"]

[my_cli.search]
exact = True

Colorization of help screen

Extend Cloup's own help formatter and theme to add colorization of:

  • Options
  • Choices
  • Metavars

This has been discussed upstream at:

Dependencies

Here is a graph of Python package dependencies:

click-extra dependency graph

Development

Development guidelines are the same as parent project mpm, from which click-extra originated.

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

click-extra-1.1.0.tar.gz (20.1 kB view details)

Uploaded Source

Built Distribution

click_extra-1.1.0-py3-none-any.whl (30.2 kB view details)

Uploaded Python 3

File details

Details for the file click-extra-1.1.0.tar.gz.

File metadata

  • Download URL: click-extra-1.1.0.tar.gz
  • Upload date:
  • Size: 20.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for click-extra-1.1.0.tar.gz
Algorithm Hash digest
SHA256 fdd1ecc6ab10f5fe2e4ae3b10238013948f3e93df181aef34c0e0dbba3924d2b
MD5 6b5dfeaee33eb1086acf51291a7adbb3
BLAKE2b-256 f70ef7179a6685313e61869dd70c418f5f566c906e25dddce0e18a136292fbe9

See more details on using hashes here.

File details

Details for the file click_extra-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: click_extra-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 30.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.7

File hashes

Hashes for click_extra-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d17d1cf8b06021f9ba41dcf401387855e80de259c042f11dcf1befb6f78c8dd3
MD5 4dd7f8a9f24b74fcb7e9149173d51d08
BLAKE2b-256 3e242e2ba8e754530aeb829c5f7e03b6fdbc5abfd5888c5eb7a422024da56e57

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page