About prestashop-update
A skill that guides operators through updating a PrestaShop store with Update Assistant. It gates the process on readiness checks and user confirmation, then backs up, updates, and can restore the store if needed.
Key features
- 01Check versions and update requirements
- 02Review modified core and theme files
- 03Summarize errors and warnings
- 04Require confirmation before proceeding
- 05Back up, update, or restore the store
Use cases
- 01Prepare and perform a PrestaShop update
- 02Resolve reported blockers before updating
- 03Restore a backup after an update issue
Install
Copy the command and run it in a terminal.
$
npx skills add https:/ / github.com/ prestashop/ skills --skill prestashop-updateAfter installing, type/prestashop-updatein Claude Code to confirm it loaded.
Details
From the project READMEPrestaShop - Updating to a newer version of PrestaShop
Requirements
Ask the user:
- What is the path to the module
autoupgradefrom the store. It may be in a Docker container or behind a SSH session. - What is the admin folder name if you don't know it. It will be needed to run commands.
Usage:
- The commands of Update Assistant are run with
[module_path]/bin/console, - Commands details are provided by adding
--helpat the end. - The param
-qavoids unecessary contents to be displayed. If you need to access the logs after a backup, an update or a restore, you can find them in[admin_path]/autoupgrade/logs/with files in the format[year]-[month]-[day]-[time]-[action].txt.
Steps
- Run
update:check-new-versionand display available versions (GATE). 3 channels may appear:online_recommended(default),onlineor local.online_recommendedandonlinemay not always appear.localrequires the zip and xml files of the newer version of PrestaShop to be present in[shop_admin]/autoupgrade/download/. Ask the user to select the channel that will be used during the next steps - Check the compatibility of the store with
update:check-requirements. Additional checks can be done when specific feedback is displayed:- If the core files are modified (except index.php files and modules), you can assess how the changes are critical to the merchants by diffing from the original file on GitHub with the URL https://raw.githubusercontent.com/PrestaShop/PrestaShop/refs/tags/[prestashop_source_version]/[path_to_file_from_root_store] (the placeholders have to be replaced with actual values). If the changes are critical for the business, recommend to move them in a module to avoid loosing them, or as last resort an override.
- If theme files are modified (except index.php files), you can assess how the changes are critical to merchants by diffing from the original file on GitHub with the URL https://raw.githubusercontent.com/PrestaShop/[theme_name]/refs/tags/[version_in_config/theme.yml_of_the_theme]/[path_to_file_from_root_store] (the placeholders have to be replaced with actual values). If the changes are critical for the business, recommend to move them in a child theme to avoid loosing them. This is only when assessing changes from default PrestaShop themes:
classic, andhummingbird.
- Check the posts related to the current version of Update Assistant on https://github.com/PrestaShop/autoupgrade/discussions/categories/known-issues?discussions_q=is%3Aopen+category%3A%22Known+issues%22+label%3A%22Impacts%3A+[version]%22 by replacing [version] with the current major.minor version of the module. It can be found by running
[module_path]/bin/consolewithout any parameter. - Conclude with a clear go / no-go recommendation with a summary of errors / warnings / successes using the Severity levels below. If there are errors, investigate and request confirmation to fix them (automatically if there is a way to do so, wait for the user to suggest a fix, wait for the user to fix it himself) and run the command again (GATE).
- When there are no more errors (warnings are acceptable), ask the user if he want to proceed with the update (GATE).
- Backup the store with
backup:create -q. This is a long process depending on the size of the store. - Run the update with
update:start -q(TODO: Add param to know the command is run by an agent in analytics). This is a long process depending on the size of the store. - If the process ends with a successful message, let the user know it is possible to use the store and make sure everything works as expected (GATE).
- In case of issue, the backup created by Update Assistant can be restored with
backup:restore. This is a long process depending on the size of the store.
Severity levels
| Marker | Severity | Meaning |
|---|---|---|
| 🔴 | Error | An issue that must be fixed before updating |
| 🟡 | Warning | Minor issue, worth fixing but not blocking |
| 🟢 | OK | A check that did not returned anything to fix or confirmed the readyness |
Comments
Markdown supported