Skip to main content

Quick python reference for terminal color escape codes

Project description

clicolor

PyPI version Build Status

Quick python reference for terminal color escape codes

Usage

Install options:

  • Install the package clicolor

  • Add as a submodule

git submodule add https://github.com/camas/clicolor
  • Or just copy cli.py and LICENSE somewhere

Then from clicolor.cli import CLI, ...

Examples

print(f"{CLI.BG_YELLOW}{CLI.GREEN}Green on yellow.{CLI.RESET}")

Green text on yellow background example

print(f"{CLI.BOLD}{CLI.RED}Bold red.{CLI.RESET}")

Bold red text example

print(f"{CLIT.bg(128,0,0)}{CLIT.fg(255,99,71)}Truecolor tomato red on maroon red background{CLI.RESET}")

Truecolor red example

test.py

use test.py to run a variety of tests including modifiers, 8/16 colors, 256 colors and Truecolors.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

clicolor-1.0.7.tar.gz (6.6 kB view details)

Uploaded Source

Built Distribution

clicolor-1.0.7-py3-none-any.whl (7.1 kB view details)

Uploaded Python 3

File details

Details for the file clicolor-1.0.7.tar.gz.

File metadata

  • Download URL: clicolor-1.0.7.tar.gz
  • Upload date:
  • Size: 6.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.1

File hashes

Hashes for clicolor-1.0.7.tar.gz
Algorithm Hash digest
SHA256 cdd13b78654a6bb06486597c5292cdf0fe482cea1025e854b5256f0d159cd49a
MD5 f8da597d0a29c4fa45610e22f6650f1e
BLAKE2b-256 9e2d40a4af055e17da98be4496b30d4b018d705aeccdee77578fb2a2891390f1

See more details on using hashes here.

File details

Details for the file clicolor-1.0.7-py3-none-any.whl.

File metadata

  • Download URL: clicolor-1.0.7-py3-none-any.whl
  • Upload date:
  • Size: 7.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.1

File hashes

Hashes for clicolor-1.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 6262b22c5d46186d8322616bd85524a56773fa29fdb20fe488ffc7d21f798096
MD5 b9bbf3d721dc7399ff9f84e473114d30
BLAKE2b-256 f57db0a027dab665dad681b02c1c8ddb346a3afcaa57240be6f7467c613be94f

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