protected function execute(InputInterface $input, OutputInterface $output) { $output->writeln('Route列表:'); $routeList = Route::getRoutes(); var_dump($routeList); }
webman/console 支持了打印路由列表功能。 ./webman route:list
./webman route:list
and where to get webman/console? I don't have the ./webman file
Run command composer require webman/console. This command requires workerman/webman>=1.2.2 and workerman/webman-framework>=1.2.1
composer require webman/console
workerman/webman>=1.2.2
workerman/webman-framework>=1.2.1
Thanks!
使用不了,報(bào)錯 There are no commands defined in the "group" namespace.
There are no commands defined in the "group" namespace.
使用 ./webman route:list
是不是本地項(xiàng)目和線上哪里不一致? 創(chuàng)建新項(xiàng)目composer create-project workerman/webman 然后試下
composer create-project workerman/webman
我本地代碼和weban官方的更新成完全一致了,還是不行,不知道怎么回事?哈哈
我知道怎么回事了,等下我修復(fù)下
好的
好了,更新到 workerman/webman v1.2.2 workerman/webman-framework v1.2.1
workerman/webman
workerman/webman-framework
謝謝,可以啦!
可以啦