sbolch / console-helper
Makes console formatting easier.
Fund package maintenance!
sbolch
Ko Fi
Buy Me A Coffee
wise.com/pay/me/szabolcss237
Installs: 5
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 0
Open Issues: 0
Type:package
Requires
- php: >=7.2
README
Makes console formatting easier.
Installation
Open a command console, enter your project directory and execute the following command to download the latest stable version of this bundle:
$ composer require sbolch/console-helper
This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation.
Usage
use sbolch\ConsoleHelper; echo ConsoleHelper::success("Task completed.\n"); echo ConsoleHelper::error("Failure!\n"); echo ConsoleHelper::warning("Attention!\n"); echo ConsoleHelper::info('5 items updated.'); echo ConsoleHelper::replace(ConsoleHelper::info('6 items updated.')); echo "\n"; echo ConsoleHelper::replaceLine('All previous lines are replaced with this.', 4); echo ConsoleHelper::progress( 50, // percentage 10 // width in characters, default is 20 ); // prints this: █████░░░░░