2022-10-16 19:46:42 +00:00
|
|
|
#!/bin/sh
|
|
|
|
# shellcheck disable=SC2034
|
|
|
|
# SC2034: "Variable appears unused. Verify it or export it."
|
|
|
|
# Those are intentional here, as the file is meant to be included elsewhere.
|
|
|
|
|
2022-11-23 20:01:11 +00:00
|
|
|
# NOTE: If using another privilege escalation binary make sure it is configured or has the appropiate flag
|
|
|
|
# to keep the current environment variables in the launched process (in sudo's case this is achieved
|
|
|
|
# through the -E flag described in sudo(8).
|
|
|
|
SUDO="sudo -E"
|
2022-10-16 19:46:42 +00:00
|
|
|
|
|
|
|
if [ "$(uname -s)" = "SerenityOS" ]; then
|
2022-11-23 20:01:11 +00:00
|
|
|
SUDO="pls -E"
|
2022-10-16 19:46:42 +00:00
|
|
|
fi
|
|
|
|
|
|
|
|
die() {
|
|
|
|
echo "die: $*"
|
|
|
|
exit 1
|
|
|
|
}
|