phar打包的时候遇到报错

bindow

问题描述

phar打包报错了,webman/console 是最新的

程序代码

php webman phar:pack

报错信息

There are no commands defined in the "phar" namespace.

截图报错信息里报错文件相关代码

截图

100 2 0
2个回答

damao

webman/console 版本不是最新的

  • bindow 9天前

    是最新的

    WWW@api api % composer update webman/console
    Loading composer repositories with package information
    Updating dependencies
    Nothing to modify in lock file
    Writing lock file
    Installing dependencies from lock file (including require-dev)
    Nothing to install, update or remove
    Generating autoload files
    38 packages you are using are looking for funding.
    Use the composer fund command to find out more!
    No security vulnerability advisories found.
    WWW@api api % php webman phar:pack
    There are no commands defined in the "phar" namespace.

  • damao 9天前

    https://packagist.org/packages/webman/console
    composer info 看下版本,是不是用了有问题的composer镜像,尤其是阿里云composer镜像

北月妖王

这个问题是因为这个命令取消了,一开始确实是用 phar:pack ,后来 @walkor 大佬添加了 build:bin 这个命令,为了统一命令风格就把 phar:pack 重命名成了 build:phar ,当时保留了 phar:pack 别名命令,只是前段时间提交了 bug 修复,就顺便把 phar:pack 这个别名命令取消了。

  • bindow 8天前

    换成build:phar可以了,感谢

🔝