mirror of
https://github.com/Matir/skel.git
synced 2026-05-26 13:35:42 -07:00
Always try sudo if needed.
This commit is contained in:
@@ -221,7 +221,7 @@ run_as_root() {
|
||||
if [ ${USER} = "root" ] ; then
|
||||
"$@"
|
||||
return $?
|
||||
elif groups | grep -q '\bsudo\b' ; then
|
||||
elif test -x $(which sudo 2>/dev/null) ; then
|
||||
verbose "Using sudo to run ${1}..."
|
||||
sudo "$@"
|
||||
return $?
|
||||
|
||||
Reference in New Issue
Block a user