From 674c998e93762e0228d1415190c4ed503aed8f56 Mon Sep 17 00:00:00 2001 From: Andrew Lytvynov Date: Mon, 17 Jun 2024 10:33:26 -0700 Subject: [PATCH] cmd/tailscale/cli: do not allow update --version on macOS (#12508) We do not support specific version updates or track switching on macOS. Do not populate the flag to avoid confusion. Updates #cleanup Signed-off-by: Andrew Lytvynov --- cmd/tailscale/cli/update.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmd/tailscale/cli/update.go b/cmd/tailscale/cli/update.go index 8e6a9fcb1..69d1aa97b 100644 --- a/cmd/tailscale/cli/update.go +++ b/cmd/tailscale/cli/update.go @@ -33,11 +33,13 @@ // - Alpine (and other apk-based distros) // - FreeBSD (and other pkg-based distros) // - Unraid/QNAP/Synology + // - macOS if distro.Get() != distro.Arch && distro.Get() != distro.Alpine && distro.Get() != distro.QNAP && distro.Get() != distro.Synology && - runtime.GOOS != "freebsd" { + runtime.GOOS != "freebsd" && + runtime.GOOS != "darwin" { fs.StringVar(&updateArgs.track, "track", "", `which track to check for updates: "stable" or "unstable" (dev); empty means same as current`) fs.StringVar(&updateArgs.version, "version", "", `explicit version to update/downgrade to`) }