This forum is in READ-ONLY mode.
You can look around, but if you want to ask a new question, please use Stack Overflow.

clearCache Error on dev bundles with --no-dev option

Discuss installing Symfony 2 here

clearCache Error on dev bundles with --no-dev option

by zajca » Wed Jul 16, 2014 1:04 pm

I want to deploy Symfony 2.5 application (Symfony 3 structure).

And I run to problem with packages in require-dev section. When I want to deploy application and run composer with --no-dev option. It fail in post-install script clearCache.

Code: Select all
PHP Fatal error:  Class 'Sensio\Bundle\GeneratorBundle\SensioGeneratorBundle' not found in /.../app/AppKernel.php on line 26
Script Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache handling the post-install-cmd event terminated with an exception

It's obvious that build fails because SensioGeneratorBundle isn't installed since it's in require-dev

But the question is. How can I avoid this and run composer with --no-dev option?

Or I have to run composer without --no-dev even if the bundle is in AppKernel in section for "dev" and "test"?

The reason for this question is that --no-dev option is in documentation ""
Junior Member
Posts: 3
Joined: Fri Sep 06, 2013 10:48 am