unknownrori / cli
一个简化 CLI 开发的简单包
0.3-alpha
2022-07-23 09:08 UTC
Requires
- php: >= 7.4
Requires (Dev)
- phpunit/phpunit: ^9.5
README
这个库用于简化 PHP 的 CLI 开发。
使用方法
use UnknownRori\Console\Console; $app = new Console(); // Add command $app->addCommand('sum', "It sum a two number", function (float $a, float $b) { return $a + $b; }); // Serving the cli echo $app->serve($argv);
入门
通过 composer 安装
> composer require unknownrori/cli
需求
php 7.4