Command Line Tools
wheels plugin update
wheels plugin update
Section titled “wheels plugin update”Update a Wheels plugin to the latest or a specified version from ForgeBox.
wheels plugin update <name> [--version=<version>] [--force]Parameters
Section titled “Parameters”| Parameter | Required | Type | Description |
|---|---|---|---|
name | Yes | string | Name, slug, or folder name of the plugin to update |
version | No | string | Specific version to update to (default: latest) |
force | No | boolean | Force update even if already at latest version |
Description
Section titled “Description”The plugin update command updates an installed Wheels plugin from the /plugins folder. It checks ForgeBox for the latest version, compares with the installed version, and performs the update if needed.
Features
Section titled “Features”- Smart version checking (prevents unnecessary updates)
- Flexible plugin matching (by name, slug, or folder name)
- Real-time version queries from ForgeBox
- Clean removal and reinstallation process
- Helpful success and error messages
- Beautiful, color-coded output
Examples
Section titled “Examples”Update to latest version
Section titled “Update to latest version”wheels plugin update bcryptOutput:
=========================================================== Updating Plugin: bcrypt===========================================================
Plugin: bcryptCurrent version: 0.0.3Latest version: 0.0.4
Target version: 0.0.4===========================================================
Removing old version...Installing new version...
[CommandBox installation output...]
===========================================================
[OK] Plugin 'bcrypt' updated successfully!
Commands: wheels plugin info bcrypt View plugin details wheels plugin list View all installed pluginsPlugin already up to date
Section titled “Plugin already up to date”wheels plugin update bcryptOutput:
================================================== Updating Plugin: bcrypt==================================================
Plugin Information--------------------------------------------------Plugin: CFWheels bCryptCurrent version: 1.0.2Latest version: 1.0.2
[SUCCESS]: Plugin is already at the latest version (1.0.2)
[INFO]: Use --force to reinstall anyway - wheels plugin update bcrypt --forceUpdate to specific version
Section titled “Update to specific version”wheels plugin update bcrypt --version=0.0.3Output:
=========================================================== Updating Plugin: bcrypt===========================================================
Plugin: bcryptCurrent version: 0.0.4Latest version: 0.0.4
Target version: 0.0.3===========================================================
Removing old version...Installing new version...
[CommandBox installation output...]
===========================================================
[OK] Plugin 'bcrypt' updated successfully!
Commands: wheels plugin info bcrypt View plugin details wheels plugin list View all installed pluginsForce reinstall
Section titled “Force reinstall”wheels plugin update bcrypt --forceOutput:
=========================================================== Updating Plugin: bcrypt===========================================================
Plugin: bcryptCurrent version: 0.0.4Latest version: 0.0.4
Target version: 0.0.4===========================================================
Removing old version...Installing new version...
[CommandBox installation output...]
===========================================================
[OK] Plugin 'bcrypt' updated successfully!
Commands: wheels plugin info bcrypt View plugin details wheels plugin list View all installed pluginsPlugin not installed
Section titled “Plugin not installed”wheels plugin update nonexistent-pluginOutput:
=========================================================== Updating Plugin: nonexistent-plugin===========================================================
[ERROR] Plugin not found
Plugin 'nonexistent-plugin' is not installed
Install this plugin: wheels plugin install nonexistent-pluginCannot reach ForgeBox
Section titled “Cannot reach ForgeBox”wheels plugin update bcryptOutput (network error):
=========================================================== Updating Plugin: bcrypt===========================================================
Plugin: bcryptCurrent version: 0.0.4
Error checking ForgeBox: Connection timeout
Unable to verify if update is needed
Options: - Specify a version: wheels plugin update bcrypt --version=x.x.x - Force reinstall: wheels plugin update bcrypt --forceUpdate Process
Section titled “Update Process”- Find Plugin: Searches
/pluginsfolder for matching plugin by name, slug, or folder name - Read Metadata: Extracts current version and slug from plugin’s
box.json - Query ForgeBox: Uses
forgebox showcommand to get latest version - Version Comparison: Cleans and compares versions to check if update needed
- Skip if Up-to-Date: Exits early if already at target version (unless
--force) - Remove Old Version: Deletes the plugin folder
- Install New Version: Uses PackageService to download and install from ForgeBox
- Verify Location: Moves plugin to
/pluginsif installed elsewhere - Confirm Success: Displays success message with helpful commands
Plugin Matching
Section titled “Plugin Matching”The command uses a smart matching algorithm to find plugins by:
- Folder name (e.g.,
bcrypt) - Slug from box.json (e.g.,
cfwheels-bcrypt) - Name from box.json (e.g.,
bcrypt,CFWheels Bcrypt) - Normalized variations (strips
cfwheels-andwheels-prefixes)
This means you can update using any of these:
wheels plugin update bcryptwheels plugin update cfwheels-bcryptwheels plugin update "CFWheels Bcrypt"Version Comparison
Section titled “Version Comparison”The command cleans versions before comparison:
- Removes all non-numeric characters except dots
- Example:
v0.0.4becomes0.0.4 - Example:
0.0.4-betabecomes0.0.4 - Compares cleaned strings for equality
If versions match, the plugin is considered up-to-date.
Force Flag
Section titled “Force Flag”Use --force to reinstall even when already up-to-date. Useful for:
- Recovering from corrupted installations
- Forcing cache refresh
- Testing installation process
- Reinstalling after manual modifications
Error Handling
Section titled “Error Handling”Plugins Directory Not Found
Section titled “Plugins Directory Not Found”[ERROR] Plugins directory not foundPlugin 'bcrypt' is not installedPlugin Not Installed
Section titled “Plugin Not Installed”[ERROR] Plugin not foundPlugin 'bcrypt' is not installed
Install this plugin: wheels plugin install bcryptForgeBox Query Failed
Section titled “ForgeBox Query Failed”Error checking ForgeBox: [error message]
Unable to verify if update is needed
Options: - Specify a version: wheels plugin update bcrypt --version=x.x.x - Force reinstall: wheels plugin update bcrypt --forceInstallation Failed
Section titled “Installation Failed”[ERROR] Error updating pluginError: [error message]Best Practices
Section titled “Best Practices”- Check First: Use
wheels plugin outdatedto see which plugins need updates - Update One at a Time: Test each plugin update individually
- Read Release Notes: Check ForgeBox for breaking changes
- Test in Development: Update in dev environment before production
- Keep Backups: Commit your code before updating plugins
- Only updates plugins from
/pluginsfolder - Only works with
cfwheels-pluginstype packages - Removes old version completely before installing new version
- Uses ForgeBox slug for installation to ensure correct package
- Requires internet connection to query ForgeBox
- Version check is performed in real-time (not cached)
- After update, plugin may require application reload
- If installation fails, the old version is already removed (no automatic rollback)
- The command uses CommandBox’s PackageService for downloading
See Also
Section titled “See Also”- wheels plugin update:all - Update all plugins
- wheels plugin outdated - Check for outdated plugins
- wheels plugin info - View plugin details
- wheels plugin list - List installed plugins