go-upgrade

command module
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 3, 2026 License: MIT Imports: 11 Imported by: 0

README

go-upgrade

Build Status License Release

Update outdated Go module dependencies interactively.

go-upgrade scans a Go module, shows available upgrades, and lets you apply updates interactively. It preserves color-coded output to indicate update types and can run non-interactively for CI or scripted workflows.

Downloads

Install (with Go)

  • With the Go toolchain and modules enabled:
go install github.com/devsolux/go-upgrade@latest
go-upgrade --help

Quick check (no interactivity)

  • To list available upgrades without entering the interactive UI:
go-upgrade --list

Color legend

  • yellow — minor update
  • green — patch update
  • red — prerelease update

Global options

  • Use these flags to control behavior (suitable for CI or local use):
GLOBAL OPTIONS:
   --pagesize value, -p value  Specify page size (default: 10)
   --force, -f                 Force update all modules in non-interactive mode (default: false)
   --list, -l                  List available module upgrades without interactivity (default: false)
   --verbose, -v               Verbose mode (default: false)
   --hook value                Hook to execute for each updated module
   --ignore value, -i value    Ignore modules matching the given regular expression
   --help, -h                  Show help (default: false)
   --version                   Print the version (default: false)

Notes

  • Use --force for automated updates in CI.
  • Use --ignore to skip modules that should not be upgraded.
  • Hooks allow custom scripts to run for each updated module.
  • Interactive selection keys: up/down or k/j to move, space to toggle, a to toggle all, enter to confirm, q or esc to cancel.

Helpful (macOS)

BINARY
curl -L -o go-upgrade_0.1.0_darwin_arm64.tar.gz https://github.com/devsolux/go-upgrade/releases/download/v0.1.0/go-upgrade_0.1.0_darwin_arm64.tar.gz
tar -xzf go-upgrade_0.1.0_darwin_arm64.tar.gz
cd go-upgrade_0.1.0_darwin_arm64
sudo mv go-upgrade /usr/local/bin/go-upgrade
chmod +x /usr/local/bin/go-upgrade

which go-upgrade
go-upgrade --help
GOPATH
echo 'export GOPATH="${GOPATH:-$HOME/go}"' >> ~/.zshrc
echo 'export PATH="$PATH:$GOPATH/bin"' >> ~/.zshrc
exec $SHELL -l
CLI
# List installed tool binaries
ls -lh "$(go env GOPATH)/bin"

# Remove installed tool binaries
rm -rf "$(go env GOPATH)/bin"

# Clear module and build caches
go clean -modcache -cache -testcache -fuzzcache
DOCTOR
which go
go env GOROOT GOPATH GOBIN
echo $PATH
ls -1 "$(go env GOPATH)/bin" | sed -n '1,10p'

which go-upgrade
$(go env GOPATH)/bin/go-upgrade --list

License

This project is licensed under the terms described in the LICENSE file.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
internal
app
ui

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL