Skip to main content

Mini-lib to strip ANSI escape codes from strings

Project description

Ansistrip

Mini-lib to strip ANSI Escape codes from a string.

Installation

Install with uv:

uv add ansistrip

Usage

In [1]: import ansistrip

In [2]: text =  "\x1b[1m\x1b[38;5;10mtest\x1b0m"

In [3]: ansistrip.ansi_strip(text)

Out[3]: 'test'

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

ansistrip-0.2.3.tar.gz (2.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ansistrip-0.2.3-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

Details for the file ansistrip-0.2.3.tar.gz.

File metadata

  • Download URL: ansistrip-0.2.3.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for ansistrip-0.2.3.tar.gz
Algorithm Hash digest
SHA256 db19ada19b3bd840ce36dc75139891fc061372271c4c4bc30bca217a1eb94888
MD5 90298b7c683808a0450cd2b91e777e64
BLAKE2b-256 543102a716b9bc434320ef3bbcf38c070b3931436de0eea75a90088b9f4b9ccd

See more details on using hashes here.

File details

Details for the file ansistrip-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: ansistrip-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 2.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for ansistrip-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 f91ea52c011069b7533dc252070f594e5f15a2f11006f562364f8670cfa1941b
MD5 09f51e0c2f3d30836a73e5a973db8355
BLAKE2b-256 51cec740a2ddb788e0b30d536bb9944ba3c24eb8fe407eaec334ddf67e610c03

See more details on using hashes here.

Supported by

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