-
Notifications
You must be signed in to change notification settings - Fork 1
feat: Update commercial if it is also installed #13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -56,6 +56,12 @@ public function update(string $file, string $latestVersion): void | |
| $composerJson['require'][$shopwarePackage] = $version; | ||
| } | ||
|
|
||
| if (isset($composerJson['require']['shopware/commercial'])) { | ||
| // If commercial is installed, also update it directly as part of the core update to keep them in sync | ||
| // Remove leading "(v)6." from Shopware version to match commercial release versions | ||
| $composerJson['require']['shopware/commercial'] = substr($version, strpos($version, '.') + 1); | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The entire bootstrapping of extension loading is forgotten at this place. How does Composer will get the next version? The plugin can be in:
To fulfill this, you will need packages.shopware.com. This is right now on 0% of Shops configured who uses the WebInstaller, if they already now our packages, they might not use this tool at all anymore. There are still no API to gather the packages token, so you will have to fallback to regular API Download which we have in core. But the application might me such in a unstable state, that an When we wanna open this Topic really, I would push further that we authenticate every Shopware instance against packages.shopware.com, and only use that mechanism. I would not port the existing uggly zip downloading to there. The store packages, would solve this problem also for PayPal plugin whatever else requires this in future
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is the mentioned issue, we should do first shopware/shopware#13631 |
||
| } | ||
|
|
||
| $composerJson = $this->configureRepositories($composerJson); | ||
|
|
||
| file_put_contents($file, json_encode($composerJson, \JSON_THROW_ON_ERROR | \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES)); | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we need to ensure, that the given
$versionis of format(v)11.22.33.44.I am not sure, if "versions" like
dev-trunkare also possible at this point 🤔