diff --git a/client/internal/elevate/output.go b/client/internal/elevate/output.go index 2ff0bc143..6e1646bd3 100644 --- a/client/internal/elevate/output.go +++ b/client/internal/elevate/output.go @@ -6,7 +6,6 @@ import "strings" // said still reads as a sentence. const noOutput = "no output" -// firstLine trims captured output to something that reads in one line. func firstLine(s string) string { s = strings.TrimSpace(s) if s == "" { diff --git a/client/internal/elevate/run_unix.go b/client/internal/elevate/run_unix.go index 4a37670e2..b2de09a49 100644 --- a/client/internal/elevate/run_unix.go +++ b/client/internal/elevate/run_unix.go @@ -1,4 +1,4 @@ -//go:build linux || freebsd +//go:build linux package elevate diff --git a/client/internal/elevate/run_unix_test.go b/client/internal/elevate/run_unix_test.go index d9a9f900a..c868f9a74 100644 --- a/client/internal/elevate/run_unix_test.go +++ b/client/internal/elevate/run_unix_test.go @@ -1,4 +1,4 @@ -//go:build linux || freebsd +//go:build linux package elevate diff --git a/client/internal/elevate/run_unsupported.go b/client/internal/elevate/run_unsupported.go index 887525c4b..d1daf3184 100644 --- a/client/internal/elevate/run_unsupported.go +++ b/client/internal/elevate/run_unsupported.go @@ -1,11 +1,15 @@ -//go:build !windows && !darwin && !linux && !freebsd +//go:build !windows && !darwin && !linux package elevate import "context" -// run reports that this platform has no elevation prompt to drive. Mobile and -// WASM builds have no local user to ask in the first place. +// run reports that this platform has no elevation prompt to drive. +// +// The desktop app is the only caller and is not built for any of these: mobile +// and WASM have no local user to ask, and the FreeBSD client ships without a UI. +// pkexec would be the mechanism there, and run_unix.go is what to widen if that +// changes. func run(context.Context, string, []string) error { return ErrUnavailable }