A macOS utility that automates upgrading CubeCart installations while preserving your customisations. It detects your current version, downloads the latest release from GitHub, and intelligently merges your custom changes into the new version.
- Detects your current CubeCart version and admin folder/file names from an existing installation
- Fetches the latest CubeCart release version from GitHub
- Downloads both your current and latest version archives (if not already downloaded)
- Extracts both versions and renames the admin folder/file to match your installation
- Copies your live installation as a
sourcereference - Generates patches showing:
- The stock upgrade diff (your version → latest)
- Your customisations diff (stock version → your modified source)
- Applies your customisations to the latest stock version automatically
- Reports which customisations applied cleanly and which need manual merging
- macOS
curl,diff,patch,rsync,unzip(all included with macOS)- An existing CubeCart installation accessible via the filesystem
- Clone this repository:
git clone https://github.com/cubecart/upgrade-builder.git
- Open Script Editor (Applications → Utilities → Script Editor)
- Open
main.applescriptfrom the cloned repository - Go to File → Export…
- Set File Format to Application
- Save as
CubeCart Upgrade Builder.appto your Applications folder - Copy
prepare_comparison.shinto the app bundle:cp prepare_comparison.sh "/Applications/CubeCart Upgrade Builder.app/Contents/Resources/" chmod +x "/Applications/CubeCart Upgrade Builder.app/Contents/Resources/prepare_comparison.sh"
No installation needed — just clone and run:
git clone https://github.com/cubecart/upgrade-builder.git
cd upgrade-builder
chmod +x prepare_comparison.sh- Double-click CubeCart Upgrade Builder.app
- Select your CubeCart installation folder when prompted
- Enter a prefix/domain name (e.g.
example.com) for organising the output folders - Wait for the process to complete
./prepare_comparison.sh /path/to/cubecart example.comOr run interactively (you will be prompted for each value):
./prepare_comparison.shArguments:
| Argument | Description | Example |
|---|---|---|
INSTALL_PATH |
Full path to your CubeCart installation | /var/www/html/shop |
PREFIX |
Domain or label for organising output folders | example.com |
All output is created under ~/Downloads/<prefix>/:
~/Downloads/example.com/
├── 6.4.0/ # Extracted stock FROM version
├── 6.5.0/ # Extracted stock TO version
├── source/ # Copy of your live installation
├── upgraded/ # Stock TO + your customisations applied
├── upgrade_6.4.0_to_6.5.0.patch # Stock upgrade diff
├── customisations_6.4.0.patch # Your customisations diff
└── upgrade_6.5.0_to_upgraded.patch # Final diff vs stock TO
- All customisations applied cleanly: The
upgraded/folder is ready to deploy. Review the changes, then replace your live installation. - Some conflicts detected: Clean patches are applied automatically. Conflicting files are listed in the output and need manual merging. Use the generated patch files to guide your merge.
- No customisations detected: Your installation matches stock CubeCart. Simply use the latest stock version as your upgrade.
The tool uses diff and patch under the hood:
- A customisation patch is generated by diffing stock CubeCart (your current version) against your live source. This isolates only your changes.
- The customisation patch is then applied to the latest stock release, effectively rebasing your changes onto the new version.
- Line-ending differences (CRLF vs LF) are normalised before comparison to avoid false positives.
- Only files present in the stock distribution are compared — cache, uploads, and other non-application files are ignored.
See LICENCE for details.