
gvm
A command-line tool for installing and switching between multiple Go language versions.
- Stars
- 11.7k
- Forks
- 584
- Licence
- MIT
- Language
- Shell
- Last update
- 2.2 years ago
- Type
- CLI
No commits in over a year — check for forks or alternatives before adopting.
What it is
GVM is a shell-based command-line tool that lets you install several versions of the Go programming language on one machine and switch between them. It also offers commands to list available versions, compare files in the Go installation directory, and manage separate Go workspaces (called package sets). People use it when projects need different Go versions and mixing them causes build problems.
- Install a specific Go release such as go1.4 with gvm install go1.4
- Switch the active Go version with gvm use and set it as default
- List installed versions with gvm list and available ones with gvm listall
- Create a separate package set with gvm pkgset create for an isolated workspace
Great for
- Go developers who work on several projects that need different Go versions
- Developers who need to test code against an older or newer Go release
- Engineers who want isolated dependency environments per project using package sets
- People comfortable with the terminal and shell scripts
Not ideal for
- Users who only need one Go version and can use the official installer or a package manager instead, since GVM adds setup overhead
- Windows users, because the README only documents Mac OS X, Linux, and FreeBSD requirements
- Anyone wanting a polished graphical interface, since the README describes only command-line usage
How to get it
- 1
See the README
You'll need: Bison · curl · git · Mercurial (Mac OS X and some Linux setups per the README) · gcc and make (for compiling Go from source)
Install Bison (Debian/Ubuntu)
sudo apt-get install bisonInstall gvm
bash < <(curl -s -S -L https://raw.githubusercontent.com/moovweb/gvm/master/binscripts/gvm-installer) - 2
Run it
- Install Bison and the other listed system requirements for your OS
- Run the gvm installer script from the README
- Install a Go version, for example: gvm install go1.4
- Activate it with gvm use go1.4 --default
- Check the active version with gvm list
- 3
Get the most out of it
- Use gvm install with -B to install from a binary when source builds fail
- Use --prefer-binary to try a binary install and fall back to source automatically
- Create per-project package sets with gvm pkgset and use --local for repository-specific paths
- Use gvm diff to see which files were added or removed in GOROOT
Downloads
Strengths
- Installs and switches between many Go versions from one tool
- Supports bootstrapping older Go versions needed to build newer ones, as described in the README
- Shell-based and simple to remove with gvm implode or rm -rf ~/.gvm
Trade-offs
- The README notes that Go 1.5+ requires a multi-step bootstrap process, which is error-prone
- Upgrades from older versions can leave gvm's state mixed up, according to the troubleshooting section
- The README's last push date is August 2024 and it lists no formal release, so maintenance status is uncertain
How it compares
| Project | Stars | Type | Level | Updated | Best for |
|---|---|---|---|---|---|
| gvm (this) | 11.7k | CLI | intermediate | 2.2 years ago | Go developers who work on several projects that need different Go versions |
| asdf | 25.6k | Dev tool | beginner | 5 days ago | Developers who work on several projects that need different language versions |
| cli | 46.8k | CLI | beginner | 6 days ago | Developers who already work in the terminal and use GitHub daily |
| croc | 40.8k | CLI | beginner | 4 days ago | People who need to send a file to someone without setting up a server, accounts, or port forwarding |
| lux | 31.8k | CLI | beginner | 7 months ago | People who want to save videos from supported sites to a local file from the command line |
| gitleaks | 30.6k | CLI | beginner | 9 days ago | Developers who want to catch accidentally committed credentials before they reach a shared repository |
Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.