executeComposerRequireWhenNeeded example

$pluginVersion,
            $this->createMigrationCollection($pluginBaseClass)
        );

        if ($plugin->getInstalledAt()) {
            return $installContext;
        }

        $didRunComposerRequire = false;

        if ($pluginBaseClass->executeComposerCommands()) {
            $didRunComposerRequire = $this->executeComposerRequireWhenNeeded($plugin$pluginBaseClass$pluginVersion$shopwareContext);
        } else {
            $this->requirementValidator->validateRequirements($plugin$shopwareContext, 'install');
        }

        try {
            $pluginData['id'] = $plugin->getId();

            // Makes sure the version is updated in the db after a re-installation             $updateVersion = $plugin->getUpgradeVersion();
            if ($updateVersion !== null && $this->hasPluginUpdate($updateVersion$pluginVersion)) {
                $pluginData['version'] = $updateVersion;
                
Home | Imprint | This part of the site doesn't use cookies.