Yii2控制台命令在Linux上不起作用(基本应用程序) [英] Yii2 console commands not working linux (basic application)

查看:103
本文介绍了Yii2控制台命令在Linux上不起作用(基本应用程序)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图将Chiliec/yii2-vote小部件添加到我的项目中.但是,当我尝试运行迁移时,什么也没发生,所以我尝试了其他命令,它们也没有执行任何操作

I was trying to add Chiliec/yii2-vote widget to my project. However when I tried to run the migration nothing happens so I tried other commands and they also do nothing

任何帮助/建议都将不胜感激.

Any help/suggestions would be appreciated.

[kyle@kyle-pc blog]$ ./yii help
./yii: line 3: ?php: No such file or directory
./yii: line 4: /bin: Is a directory
./yii: line 5: assets: command not found
./yii: line 6: assets: command not found
./yii: line 7: assets: command not found
./yii: line 8: syntax error near unexpected token `('
./yii: line 8: ` * @copyright Copyright (c) 2008 Yii Software LLC'

推荐答案

我认为您的php cli配置有问题,因为即使 yii帮助也没有任何输出.

I think that's something wrong with your php cli config because even the yii help doesn't have any output.

如果运行此命令,是否返回某些内容?

If you run this command, does return something?

php -r "echo 'Hello, world.';"

您可以尝试在CLI config.ini中启用错误消息,也可以尝试来自

You can try enabling the error messages in your CLI config.ini you can try other tips from here

这篇关于Yii2控制台命令在Linux上不起作用(基本应用程序)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆