PHPackages                             jrb-it/php-cli - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [CLI &amp; Console](/categories/cli)
4. /
5. jrb-it/php-cli

ActiveLibrary[CLI &amp; Console](/categories/cli)

jrb-it/php-cli
==============

Easy command line scripts for PHP with opt parsing and color output. No dependencies

1.0.0(2y ago)01.2k1MITPHPPHP &gt;=5.3.0

Since Jun 8Pushed 2y agoCompare

[ Source](https://github.com/JRB-IT/php-cli)[ Packagist](https://packagist.org/packages/jrb-it/php-cli)[ RSS](/packages/jrb-it-php-cli/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (1)Versions (2)Used By (1)

PHP-CLI
=======

[](#php-cli)

PHP-CLI is a simple library that helps with creating nice looking command line scripts.

It takes care of

- **option parsing**
- **help page generation**
- **automatic width adjustment**
- **colored output**
- **optional PSR3 compatibility**

It is lightweight and has **no 3rd party dependencies**. Note: this is for non-interactive scripts only. It has no readline or similar support.

Installation
------------

[](#installation)

Use composer:

`php composer.phar require splitbrain/php-cli`

Usage and Examples
------------------

[](#usage-and-examples)

Minimal example:

```
#!/usr/bin/php
