From 9fdd2242feda4b1cc933355c92ecc32128a0bf00 Mon Sep 17 00:00:00 2001 From: matks Date: Fri, 8 Sep 2023 22:12:17 +0200 Subject: [PATCH 1/6] Do not check version if not provided --- classes/UpgradeSelfCheck.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/classes/UpgradeSelfCheck.php b/classes/UpgradeSelfCheck.php index b75fb3b86..79185edda 100644 --- a/classes/UpgradeSelfCheck.php +++ b/classes/UpgradeSelfCheck.php @@ -526,6 +526,10 @@ public function isApacheModRewriteEnabled() */ public function checkKeyGeneration() { + if ($this->upgrader->version_num === null) { + return true; + } + // Check if key is needed on the version we are upgrading to, if lower, not needed if (version_compare($this->upgrader->version_num, '8.1.0', '<')) { return true; From 550ffa3e849315befdc3794bedf6a29c7aad7b95 Mon Sep 17 00:00:00 2001 From: matks Date: Tue, 12 Sep 2023 13:54:58 +0200 Subject: [PATCH 2/6] Add mention to release process in README --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index bf712ba83..91f6c54c4 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,9 @@ This module allows to upgrade your shop to a more recent version of PrestaShop. It can used as a CLI tool or with a web assistant. This module is compatible with all PrestaShop 1.7 versions. +> [!IMPORTANT] +> This module has a specific [Release Process][release-process]. If you do release a new version, make sure to follow it. + # Branches Branch `develop` contains code for future versions of the module, which allow upgrades from 1.7.x versions to higher. @@ -99,3 +102,4 @@ This module is released under the [Academic Free License 3.0][AFL-3.0] [contribution-guidelines]: https://devdocs.prestashop-project.org/8/contribute/contribution-guidelines/project-modules/ [AFL-3.0]: https://opensource.org/licenses/AFL-3.0 [doc]: https://devdocs.prestashop-project.org/8/development/upgrade-module/ +[release-process]: https://www.prestashop-project.org/maintainers-guide/processes/release/autoupgrade/ From 5542ea8123d8aaa165e471f00a41b37e94a152ad Mon Sep 17 00:00:00 2001 From: Morgan Pichat Date: Tue, 12 Sep 2023 15:01:35 +0200 Subject: [PATCH 3/6] add 2 new hooks for 8.1.2 --- upgrade/sql/8.1.2.sql | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/upgrade/sql/8.1.2.sql b/upgrade/sql/8.1.2.sql index 81ad3c831..4fc29d796 100644 --- a/upgrade/sql/8.1.2.sql +++ b/upgrade/sql/8.1.2.sql @@ -9,3 +9,7 @@ We fixed it for people installing fresh 8.1.2, but we also need to fix it for pe UPDATE `PREFIX_tab` SET wording_domain = 'Admin.Navigation.Menu', wording = 'Security' WHERE class_name = 'AdminParentSecurity'; UPDATE `PREFIX_tab` SET wording_domain = 'Admin.Navigation.Menu', wording = 'Employee Sessions' WHERE class_name = 'AdminSecuritySessionEmployee'; UPDATE `PREFIX_tab` SET wording_domain = 'Admin.Navigation.Menu', wording = 'Customer Sessions' WHERE class_name = 'AdminSecuritySessionCustomer'; + +INSERT IGNORE INTO `PREFIX_hook` (`id_hook`, `name`, `title`, `description`, `position`) VALUES + (NULL, 'actionLanguageLinkParameters', 'Add parameters to language link', 'Allows modules to provide proper parameters for links in other languages.', '1'), + (NULL, 'actionAfterLoadRoutes', 'Triggers after loading routes', 'Allow modules to modify routes in any way or add their own multilanguage routes.', '1'); From 4dd746d26724ced9a97c45e4a1b45983112f3cfc Mon Sep 17 00:00:00 2001 From: matks Date: Wed, 13 Sep 2023 10:27:37 +0200 Subject: [PATCH 4/6] Mention clearly 4.14.3 in README --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 91f6c54c4..225eb98a9 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ ## About This module allows to upgrade your shop to a more recent version of PrestaShop. It can used as a CLI tool or with a web assistant. -This module is compatible with all PrestaShop 1.7 versions. +The latest versions of the module are compatible with all PrestaShop 1.7 and higher releases. > [!IMPORTANT] > This module has a specific [Release Process][release-process]. If you do release a new version, make sure to follow it. @@ -17,9 +17,10 @@ This module is compatible with all PrestaShop 1.7 versions. # Branches Branch `develop` contains code for future versions of the module, which allow upgrades from 1.7.x versions to higher. + Branch `4.14.x` contains code for `4.14.x` patch versions which allow upgrading from 1.6.x versions to 1.7.x . -If you wish to upgrade a shop powered by PrestaShop 1.6, please use the latest 4.14.x version to upgrade to a 1.7 version. +If you wish to upgrade a shop powered by PrestaShop 1.6, **please use the latest 4.14.3 version** to upgrade to a 1.7 version. Upgrades from 1.6.x to 8.x should be done in 2 steps (1.6.x to 1.7.x then 1.7.x to 8.x). Please note PrestaShop 1.6 and older are not maintained anymore. From ef52471f9ef119157b6e0ab2891b9fc2fe9cc784 Mon Sep 17 00:00:00 2001 From: matks Date: Wed, 13 Sep 2023 10:29:05 +0200 Subject: [PATCH 5/6] Better titles structure and update link to devdoc --- README.md | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index 91f6c54c4..c7fbb3d70 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ This module is compatible with all PrestaShop 1.7 versions. > [!IMPORTANT] > This module has a specific [Release Process][release-process]. If you do release a new version, make sure to follow it. -# Branches +## Branches Branch `develop` contains code for future versions of the module, which allow upgrades from 1.7.x versions to higher. Branch `4.14.x` contains code for `4.14.x` patch versions which allow upgrading from 1.6.x versions to 1.7.x . @@ -24,16 +24,16 @@ Upgrades from 1.6.x to 8.x should be done in 2 steps (1.6.x to 1.7.x then 1.7.x Please note PrestaShop 1.6 and older are not maintained anymore. -# Prerequisites +## Prerequisites * PrestaShop 1.7 or 8 * PHP 5.6+ -# Installation +## Installation All versions can be found in the [releases list](https://github.com/PrestaShop/autoupgrade/releases). -## Create a module from source code +### Create a module from source code If you download a ZIP archive that contains the source code or if you want to use the current state of the code, you need to build the module from the sources: @@ -42,14 +42,14 @@ If you download a ZIP archive that contains the source code or if you want to us * Create a new ZIP archive from the of **autoupgrade** folder. * Now you can install it in your shop. For example, you can upload it using the dropzone in Module Manager back office page. -# Running an upgrade on PrestaShop +## Running an upgrade on PrestaShop Upgrading a shop can be done using: * the configuration page of the module (browse the back office page provided by the module) * in command line by calling the file *cli-upgrade.php* -## Command line parameters +### Command line parameters Upgrade can be automated by calling *cli-upgrade.php*. The following parameters are mandatory: @@ -62,12 +62,12 @@ The following parameters are mandatory: $ php cli-upgrade.php --dir=admin-dev --channel=major ``` -# Rollback a shop +## Rollback a shop If an error occurs during the upgrade process, the rollback will be suggested. In case you lost the page from your backoffice, note it can be triggered via CLI. -## Command line parameters +### Command line parameters Rollback can be automated by calling *cli-rollback.php*. The following parameters are mandatory: @@ -79,21 +79,21 @@ The following parameters are mandatory: $ php cli-rollback.php --dir=admin-dev --backup=V1.7.5.1_20190502-191341-22e883bd ``` -# Documentation +## Documentation Documentation is hosted on [the Developer documentation][doc]. -# Contributing +## Contributing PrestaShop modules are open source extensions to the [PrestaShop e-commerce platform][prestashop]. Everyone is welcome and even encouraged to contribute with their own improvements! Just make sure to follow our [contribution guidelines][contribution-guidelines]. -## Reporting issues +### Reporting issues You can report issues with this module in the main PrestaShop repository. [Click here to report an issue][report-issue]. -# License +## License This module is released under the [Academic Free License 3.0][AFL-3.0] @@ -101,5 +101,5 @@ This module is released under the [Academic Free License 3.0][AFL-3.0] [prestashop]: https://www.prestashop-project.org/ [contribution-guidelines]: https://devdocs.prestashop-project.org/8/contribute/contribution-guidelines/project-modules/ [AFL-3.0]: https://opensource.org/licenses/AFL-3.0 -[doc]: https://devdocs.prestashop-project.org/8/development/upgrade-module/ +[doc]: https://devdocs.prestashop-project.org/8/basics/keeping-up-to-date/upgrade-module/ [release-process]: https://www.prestashop-project.org/maintainers-guide/processes/release/autoupgrade/ From f1519731245530b50172bccbe4f15f8206845a62 Mon Sep 17 00:00:00 2001 From: Morgan Pichat Date: Wed, 13 Sep 2023 15:00:58 +0200 Subject: [PATCH 6/6] Bump version to 4.16.4 --- autoupgrade.php | 2 +- config.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/autoupgrade.php b/autoupgrade.php index bbbfcefd6..d86da025b 100644 --- a/autoupgrade.php +++ b/autoupgrade.php @@ -36,7 +36,7 @@ public function __construct() $this->name = 'autoupgrade'; $this->tab = 'administration'; $this->author = 'PrestaShop'; - $this->version = '4.16.3'; + $this->version = '4.16.4'; $this->need_instance = 1; $this->bootstrap = true; diff --git a/config.xml b/config.xml index 9a525f134..8e12cfd89 100644 --- a/config.xml +++ b/config.xml @@ -2,7 +2,7 @@ autoupgrade - +