Skip to the content.

ANSI escapes to Html

Continuous integration codecov Latest Stable Version Total Downloads License Sponsor

📢 ANSI escapes to Html is a php script that convert ANSI escapes (terminal formatting/color codes) to HTML markup:

\e[40;38;5;82m Hello \e[30;48;5;82m World

Became

<span
  style="font-weight:normal;text-decoration:none;color:rgb(95,255,0);background-color:Black;"
>
  Hello
</span>
<span
  style="font-weight:normal;text-decoration:none;color:Black;background-color:rgb(95,255,0);"
>
  World
</span>

Helping Project

❤️ If this project helps you reduce time to develop and/or you want to help the maintainer of this project. You can sponsor him. Thank you !

Contributing

👍 If you wish to contribute to this project, please read the CONTRIBUTING.md file. Note: If you want to contribute don’t hesitate, I’ll review any PR.

Documentation

  1. Installation
  2. Usage
  3. Code Coverage
  4. PHP Doc

Development

Setup

PHP_VERSION is the version of php to use during the development. Example: 8.1

make build-php PHP_VERSION
make install PHP_VERSION

Running tests

make test PHP_VERSION

Fix code linting

make lint-fix PHP_VERSION

Running CI scripts

make ci PHP_VERSION