“执行高速缓存时发生错误:clear --no-warmup"在安装symfony-cmf-standard时 [英] "An error occured when executing the cache:clear --no-warmup" while installing symfony-cmf-standard
问题描述
我正在尝试使用以下命令安装symfony-cmf-standard
I was trying to install symfony-cmf-standard using:
composer.phar create-project symfony-cmf/standard-edition symfony-cmf-standard/ --stability=dev
但是我遇到以下错误:
Could not open input file: app/console
Script sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache handling the post-install-cmd event terminated with an exception
[RuntimeException]
An error occured when executing the cache:clear --no-warmup
我正在以管理员身份运行命令,因此它应该不是权限问题.
I am running the command as an Administrator so it should not be a permission issue.
推荐答案
当我们使用命令时,它会产生错误
It gives error as when we use the command,
composer.phar create-project symfony-cmf/standard-edition symfony-cmf-standard/ --stability=dev
它将创建symfony-cmf-standard文件夹作为项目文件夹并开始安装依赖项,但是在两者之间尝试使用
It creates symfony-cmf-standard folder as a project folder and starts installing dependencies but in between it tries to clear cache using
php app/console cache:clear
但是由于当前位置不在项目文件夹中,因此无法找到应用程序/控制台,因此失败.
But as the current location is outside of the project folder it can not locate app/console so it fails.
现在,如果我们将目录更改为项目文件夹中的内容,并使用命令
Now if we change the directory to inside the project folder and clear cache manually by using command
php app/console cache:clear
它清除缓存,然后我们需要再次使用
It clears cache and then we need to again update dependencies using
php composer.phar update
对我有用.
这篇关于“执行高速缓存时发生错误:clear --no-warmup"在安装symfony-cmf-standard时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!