Download the PHP package webgriffe/sylius-upgrade-plugin without Composer
On this page you can find all versions of the php package webgriffe/sylius-upgrade-plugin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download webgriffe/sylius-upgrade-plugin
More information about webgriffe/sylius-upgrade-plugin
Files in webgriffe/sylius-upgrade-plugin
Package sylius-upgrade-plugin
Short Description Helps you upgrade your Sylius app to a new version.
License MIT
Informations about the package sylius-upgrade-plugin
Upgrade Plugin
This plugin helps you to upgrade your Sylius app to a new version.
Table of Contents
- Table of Contents
- Requirements
- Installation
- Usage
- License
- Credits
Requirements
- PHP
^8.0
- Sylius
^1.11.2 || ^1.12 || ^1.13
Installation
-
Run
composer require --dev webgriffe/sylius-upgrade-plugin
- Add the plugin to the
config/bundles.php
file:
Usage
All features are implemented as console commands.
Template changes
bin/console webgriffe:upgrade:template-changes <from-version> <to-version> [--theme=PATH_TO_YOUR_THEME] [--legacy]
Print a list of template files (with extension .html.twig) that changed between two given Sylius versions and that have been overridden in your project: in root "templates" folder and/or in a custom theme.
You have to specify both the versions from and to you want to compute the changes.
There are two optional parameters:
- --theme=PATH_TO_YOUR_THEME, specify the theme folder in which to search for changed files. The path must be relative to the kernel.project_dir of your project. You can specify multiple themes by repeating the --theme parameter, see the related example in the proper section below;
- --legacy, use legacy theme folder structure. From v2.0 of the SyliusThemeBundle the theme folder structure has changed. The old structure has been deprecated and will be removed in v3.0 as stated here.
Examples
-
List of templates that changed between Sylius v1.8.4 and v1.8.8 and that were overridden in your root templates folder:
-
List of templates that changed between Sylius v1.8.8 and v1.9.3 and that were overridden in your root templates folder and/or in your my-website-theme folder:
- Like the previous example, but it computes changes for multiple themes, one of which is in the vendor folder:
Decorated services changes
bin/console webgriffe:upgrade:service-changes <from-version> <to-version> [--theme=PATH_TO_YOUR_THEME] [--legacy]
Print a list of services that changed between two given Sylius versions and that have been decorated/overridden in your project.
You have to specify both the versions from and to you want to compute the changes.
There are two optional parameters:
- --namespace-prefix=NAMESPACE-PREFIX, the first part of the namespace of your app services, like "App" in "App\Calculator\PriceCalculator". Default: "App".
- --alias-prefix=ALIAS-PREFIX, the first part of the alias of your app services, like "app" in "app.calculator.price". Default: "app".
Examples
-
List of services that changed between Sylius v1.11.0 and v1.13.0 and that were decorated in your project:
- List of services that changed between Sylius v1.11.0 and v1.13.0 and that were decorated in your project but with custom namespace and alias prefixes:
Contributing
To contribute to this plugin clone this repository, create a branch for your feature or bugfix, do your changes and then make sure al tests are passing.
To be able to setup a plugin's database, remember to configure you database credentials in tests/Application/.env
and tests/Application/.env.test
.
Running plugin tests
-
PHPUnit
-
PHPSpec
-
Static Analysis
-
Psalm
- PHPStan
-
- Coding Standard
License
This plugin is under the MIT license. See the complete license in the LICENSE file.
Credits
Developed by Webgriffe®.
All versions of sylius-upgrade-plugin with dependencies
php-http/message-factory Version ^1.1
psr/http-factory Version ^1.0
symfony/webpack-encore-bundle Version ^1.15
sylius/sylius Version ^1.11.2 || ^1.12 || ^1.13
webmozart/glob Version ^4.3