From 900331b958429649443e06a89d38b9f8225c3546 Mon Sep 17 00:00:00 2001 From: intergrav Date: Thu, 2 Jul 2026 04:54:33 -0400 Subject: [PATCH] revert: feat: sudo-user fallback this reverts commit 050127f50d6d84e71bd4d9f0feb5168a48ef2932. --- cmd/restray/restic.go | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/cmd/restray/restic.go b/cmd/restray/restic.go index b278afe..ed8860d 100644 --- a/cmd/restray/restic.go +++ b/cmd/restray/restic.go @@ -69,16 +69,6 @@ func findResticFromShell() string { if runtime.GOOS == "windows" { return "" } - if sudoUser := os.Getenv("SUDO_USER"); sudoUser != "" { - out, err := exec.Command("sudo", "-n", "-u", sudoUser, "-i", "which", "restic").Output() - if err == nil { - if p := strings.TrimSpace(string(out)); p != "" { - if _, err := os.Stat(p); err == nil { - return p - } - } - } - } shell := os.Getenv("SHELL") if shell == "" { if runtime.GOOS == "darwin" { -- 2.51.2