PHPackages                             php-cliparser/php-cliparser - 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. php-cliparser/php-cliparser

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

php-cliparser/php-cliparser
===========================

php cli args parser

v1.0(9y ago)3161GPL v3.0PHPPHP &gt;=5.3.0

Since Jun 16Pushed 9y ago1 watchersCompare

[ Source](https://github.com/KomaBeyond/php-cliparser)[ Packagist](https://packagist.org/packages/php-cliparser/php-cliparser)[ RSS](/packages/php-cliparser-php-cliparser/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

php-cliparser
=============

[](#php-cliparser)

php 命令行参数解析器. PHP cli args parser.

Install
=======

[](#install)

```
{
    "require" :{
        "php-cliparser/php-cliparser": "~1.0"
    }
}
```

Usage
=====

[](#usage)

```
// /path/to/your/scriptfile.php --config test.yml -d -n 1 --name koma
$parser = new \CliParser\CliParser();
$parser->parse();

var_dump($parser->hasArgs('config'));
var_dump($parser->getArgs('config'));
var_dump($parser->getAllArgs());
```

[![](https://github.com/KomaBeyond/php-cliparser/raw/master/tests/Screenshot%20from%202017-06-16%2015%3A25%3A28.png)](https://github.com/KomaBeyond/php-cliparser/blob/master/tests/Screenshot%20from%202017-06-16%2015%3A25%3A28.png)

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

3301d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/164877216?v=4)[KomaBeyond](/maintainers/KomaBeyond)[@komabeyond](https://github.com/komabeyond)

---

Top Contributors

[![Kooooooma](https://avatars.githubusercontent.com/u/5483460?v=4)](https://github.com/Kooooooma "Kooooooma (6 commits)")

---

Tags

cliparserphp

### Embed Badge

![Health badge](/badges/php-cliparser-php-cliparser/health.svg)

```
[![Health](https://phpackages.com/badges/php-cliparser-php-cliparser/health.svg)](https://phpackages.com/packages/php-cliparser-php-cliparser)
```

###  Alternatives

[seld/cli-prompt

Allows you to prompt for user input on the command line, and optionally hide the characters they type

24726.4M22](/packages/seld-cli-prompt)[illuminate/console

The Illuminate Console package.

13045.3M6.2k](/packages/illuminate-console)[styleci/cli

The CLI tool for StyleCI

71464.1k9](/packages/styleci-cli)[winbox/args

Windows command-line formatter

20718.9k21](/packages/winbox-args)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
