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 pip

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.2.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.2-py3-none-any.whl (2.9 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: ansistrip-0.2.2.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.2.tar.gz
Algorithm Hash digest
SHA256 e4768b98d1bb1072bb1ba80c10cb54416910482249dee6f4c3c37ff2832ad32a
MD5 c831a1915ca3754097daba4d199d0a57
BLAKE2b-256 29e0492aa26a0b4ad4fd791dcdd8d99da41776d2d7c48e58760049ceaa9740cd

See more details on using hashes here.

File details

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

File metadata

  • Download URL: ansistrip-0.2.2-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.2-py3-none-any.whl
Algorithm Hash digest
SHA256 abac24a021f571d7897ea5c6292d0d95d1a09450e740f4390ecc31ed88fb404c
MD5 148b9dd7b52cfdd9de7c76dedb8ae98f
BLAKE2b-256 54ea0c585607583bc9584d206da8ef8c47167224069651728dea6f175b0a13d1

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