Skip to content

Upgrade ZVM

Your copy of ZVM may ship with an auto-upgrade command. If you have installed ZVM from GitHub or zvm.app you can upgrade to the latest version of ZVM with zvm upgrade.

The latest version of ZVM should install on your machine, regardless of where your binary lives (though if you have your binary in a privileged folder, you may have to run this command with sudo).

ZVM (> v0.8.14) can also be built without its auto upgrader (zvm upgrade). This is to make installing ZVM via a package manager easier for those who prefer this method.

When you run a build of ZVM with the autoupgrader disabled, you will see a builder-specified message when you run zvm upgrade.

Builder Message

Terminal window
go build -tags noAutoUpgrades \
-ldflags "-s -w -X 'main.BuildUpgradeMessage=Command to upgrade ZVM goes here.'" .

Remember, ZVM is an open source project. Anyone can customize and distribute it.

Terminal window
# Example
zvm clean

Use zvm clean to remove downloaded archives from the ZVM data directory. In v0.9.4, it also prunes files from the deduplication store that no installed version references, and per-shell links older than a week whose shells have exited.

After a successful install or upgrade, ZVM auto-cleans leftover .tar.xz and .zip artifacts under ~/.zvm/, so manual cleanup is only needed for older installs or if a download was interrupted. Run it when you also want to reclaim unused store files or stale shell links.

As of v0.8.18, zvm upgrade runs as a download → verify → atomic rename sequence. If the network drops partway through, your existing zvm binary is left untouched — you no longer end up with a half-installed executable.

On Windows, the PowerShell installer (install.ps1) now calls Unblock-File on the freshly downloaded zvm.exe to clear the “downloaded from the internet” zone flag before Windows Defender scans it. If Defender still quarantines the binary on your machine, the installer prints a clearer message pointing to your antivirus.