PHPackages                             lijinma/commander - 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. lijinma/commander

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

lijinma/commander
=================

PHP command-line interfaces made easy

0.0.4(11y ago)143404[1 issues](https://github.com/lijinma/Commander/issues)[1 PRs](https://github.com/lijinma/Commander/pulls)1MITPHPCI failing

Since Dec 25Pushed 6y ago2 watchersCompare

[ Source](https://github.com/lijinma/Commander)[ Packagist](https://packagist.org/packages/lijinma/commander)[ Docs](https://github.com/lijinma/Commander)[ RSS](/packages/lijinma-commander/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (2)Versions (5)Used By (1)

Commander
=========

[](#commander)

The solution for php command-line interfaces, inspired by [commander](https://github.com/tj/commander.js) in Node.js.

Actually some funtions in Commander is refer to [commander](https://github.com/tj/commander.js), so really thank TJ.

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

[](#installation)

```
$ composer require "lijinma/commander"

```

Option parsing
--------------

[](#option-parsing)

Options with commander are defined with the `option()` method, also serving as documentation for the options. The example below parses args and options from `$argv`.

```
