Development discussion of WireGuard
 help / color / mirror / Atom feed
* [PATCH] wg-quick: use SUDO variable for a different sudo implementation like doas
@ 2024-12-20  7:29 fossdd
  0 siblings, 0 replies; only message in thread
From: fossdd @ 2024-12-20  7:29 UTC (permalink / raw)
  To: wireguard

Signed-off-by: fossdd <fossdd@pwned.life>
---
 src/wg-quick/linux.bash | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/wg-quick/linux.bash b/src/wg-quick/linux.bash
index 4193ce5..7795c0b 100755
--- a/src/wg-quick/linux.bash
+++ b/src/wg-quick/linux.bash
@@ -82,7 +82,7 @@ read_bool() {
 }
 
 auto_su() {
-	[[ $UID == 0 ]] || exec sudo -p "$PROGRAM must be run as root. Please enter the password for %u to continue: " -- "$BASH" -- "$SELF" "${ARGS[@]}"
+	[[ $UID == 0 ]] || exec "${SUDO:-sudo}" "$BASH" -- "$SELF" "${ARGS[@]}"
 }
 
 add_if() {

base-commit: 13f4ac4cb74b5a833fa7f825ba785b1e5774e84f
-- 
2.47.1

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-05-21  9:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-12-20  7:29 [PATCH] wg-quick: use SUDO variable for a different sudo implementation like doas fossdd

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).