trb.sh: require pkexec instead of falling back to gksudo
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -6,15 +6,11 @@ if [ ! -f /usr/bin/zenity ];then
|
||||
fi
|
||||
|
||||
|
||||
distro=$(lsb_release -a | grep -o "VoidLinux")
|
||||
|
||||
auth_prompt_path=$(which pkexec)
|
||||
|
||||
if [ -f ${auth_prompt_path} ];then
|
||||
su_prompt="pkexec"
|
||||
else
|
||||
su_prompt="gksudo"
|
||||
if ! command -v pkexec >/dev/null 2>&1;then
|
||||
echo "pkexec not installed (install polkit)..."
|
||||
exit 1
|
||||
fi
|
||||
su_prompt="pkexec"
|
||||
|
||||
zenity --question --text "Do you want to trim?"
|
||||
if [[ $? == 1 ]];then
|
||||
|
||||
Reference in New Issue
Block a user