mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-21 23:20:20 +00:00
Meta: Remove dependency on sudo, doas or pls
This commit is contained in:
parent
f721230456
commit
e62f0a8da3
Notes:
sideshowbarker
2024-07-17 06:33:00 +09:00
Author: https://github.com/negge 🔰 Commit: https://github.com/LadybirdBrowser/ladybird/commit/e62f0a8da3 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/59 Reviewed-by: https://github.com/trflynn89 ✅
1 changed files with 0 additions and 16 deletions
|
@ -11,22 +11,6 @@ die() {
|
|||
exit 1
|
||||
}
|
||||
|
||||
if [ "$(uname -s)" = "SerenityOS" ]; then
|
||||
SUDO="pls -E"
|
||||
elif command -v sudo >/dev/null; then
|
||||
SUDO="sudo -E"
|
||||
elif command -v doas >/dev/null; then
|
||||
if [ "$SUDO_UID" = '' ]; then
|
||||
SUDO_UID=$(id -u)
|
||||
SUDO_GID=$(id -g)
|
||||
export SUDO_UID SUDO_GID
|
||||
fi
|
||||
# To make doas work, you have to make sure you use the "keepenv" flag in doas.conf
|
||||
SUDO="doas"
|
||||
else
|
||||
die "You need sudo, doas or pls to build Serenity..."
|
||||
fi
|
||||
|
||||
exit_if_running_as_root() {
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
die "$*"
|
||||
|
|
Loading…
Reference in a new issue