Aimeos\ShopBundle\Composer\ScriptHandler::updateConfig PHP Method

updateConfig() public static method

Ensure existing config and routing for the shop bundle.
public static updateConfig ( Composer\Script\CommandEvent $event )
$event Composer\Script\CommandEvent CommandEvent instance
    public static function updateConfig(CommandEvent $event)
    {
        $event->getIO()->write('Ensure existing config and routing for the shop bundle');
        $options = self::getOptions($event);
        if (!isset($options['symfony-app-dir']) || !is_dir($options['symfony-app-dir'])) {
            $msg = 'An error occurred because the "%1$s" option or the "%2$s" directory isn\'t available';
            throw new \RuntimeException(sprintf($msg, 'symfony-app-dir', $options['symfony-app-dir']));
        }
        self::updateConfigFile($options['symfony-app-dir'] . '/config/config.yml');
        self::updateRoutingFile($options['symfony-app-dir'] . '/config/routing.yml');
    }