Download the PHP package pointybeard/helpers-cli-colour without Composer
On this page you can find all versions of the php package pointybeard/helpers-cli-colour. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download pointybeard/helpers-cli-colour
More information about pointybeard/helpers-cli-colour
Files in pointybeard/helpers-cli-colour
Package helpers-cli-colour
Short Description Provides colour constants and a simple way to colourise strings for use on the command-line.
License MIT
Homepage https://github.com/pointybeard/helpers-cli-colour
Informations about the package helpers-cli-colour
PHP Helpers: Command-line Colour
- Version: v1.0.2
- Date: May 05 2019
- Release notes
- GitHub repository
Provides colour constants and a simple way to colourise strings for use on the command-line.
Installation
This library is installed via Composer. To install, use composer require pointybeard/helpers-cli-colour
or add "pointybeard/helpers-cli-colour": "~1.0"
to your composer.json
file.
And run composer to update your dependencies:
$ curl -s http://getcomposer.org/installer | php
$ php composer.phar update
Requirements
There are no particuar requirements for this library other than PHP 5.6 or greater.
To include all the PHP Helpers packages on your project, use composer require pointybeard/helpers
or add "pointybeard/helpers": "~1.0"
to your composer file.
Usage
Here is an example of how to use the Colour class:
Colours
The following colour constants exist:
Foreground
FG_DEFAULT, FG_BLACK, FG_RED, FG_GREEN, FG_BROWN, FG_BLUE, FG_PURPLE, FG_CYAN, FG_WHITE, FG_DARK_GRAY, FG_LIGHT_RED, FG_LIGHT_GREEN, FG_YELLOW, FG_LIGHT_BLUE, FG_LIGHT_PURPLE, FG_LIGHT_CYAN, FG_LIGHT_GRAY
Background
BG_BLACK, BG_RED, BG_GREEN, BG_YELLOW, BG_BLUE, BG_MAGENTA, BG_CYAN, BG_DEFAULT, BG_WHITE, BG_LIGHT_GRAY, BG_LIGHT_RED, BG_LIGHT_GREEN, BG_LIGHT_YELLOW, BG_LIGHT_BLUE, BG_LIGHT_MAGENTA, BG_LIGHT_CYAN, BG_DARK_GRAY
Support
If you believe you have found a bug, please report it using the GitHub issue tracker, or better yet, fork the library and submit a pull request.
Contributing
We encourage you to contribute to this project. Please check out the Contributing documentation for guidelines about how to get involved.
License
"PHP Helpers: Command-line Colour" is released under the MIT License.