From bc7602a0dfc5b550676569e9f7643847046c9212 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C5=8Dshin?= Date: Sat, 6 Jan 2024 04:08:48 +0000 Subject: [PATCH] apeuninstall.sh doas --- ape/apeuninstall.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/ape/apeuninstall.sh b/ape/apeuninstall.sh index 70cff8452..17d84145f 100755 --- a/ape/apeuninstall.sh +++ b/ape/apeuninstall.sh @@ -11,8 +11,13 @@ fi if [ "$UID" = "0" ]; then SUDO= -else +elif command -v sudo >/dev/null 2>&1; then SUDO=sudo +elif command -v doas >/dev/null 2>&1; then + SUDO=doas +else + echo "need root or sudo" >&2 + exit fi {