A collection of functions and classes to assist with command line development.
Requirements
- PHP >= 5.3
\cli\out($msg, ...)
\cli\err($msg, ...)
\cli\line($msg = '', ...)
\cli\input()
\cli\prompt($question, $default = false, $marker = ':')
\cli\choose($question, $choices = 'yn', $default = 'n')
\cli\menu($items, $default = false, $title = 'Choose an Item')
\cli\notifier\Dots($msg, $dots = 3, $interval = 100)
\cli\notifier\Spinner($msg, $interval = 100)
\cli\progress\Bar($msg, $total, $interval = 100)
\cli\Table::__construct(array $headers = null, array $rows = null)
\cli\Table::setHeaders(array $headers)
\cli\Table::setRows(array $rows)
\cli\Table::addRow(array $row)
\cli\Table::sort($column)
\cli\Table::display()
See example.php
for examples.
- Expand this README
- Add doc blocks to rest of code