Modify system menu

This commit is contained in:
2025-11-29 16:57:38 -08:00
parent e2701eda3e
commit 45269c72e4
2 changed files with 10 additions and 25 deletions

View File

@ -8,9 +8,8 @@ function is-desktop-p {
! is-laptop-p
}
echo $(is-desktop-p)
pgrep swayidle && swayidle_state="Enabled" || swayidle_state="Disabled"
systemctl --user --quiet is-active swayidle.service \
&& swayidle_state="Enabled" || swayidle_state="Disabled"
# Format: label action condition
local entries=('Select system sound output' 'select-sound-output.sh' 'true'
@ -32,7 +31,8 @@ for ((i = 1; i <= ${#entries}; i+=3)); do
fi
done
local scripts_dir="$(dirname "$(realpath "${0}")")"
local scripts_dir="${1:h:P}"
echo ${scripts_dir}
choice="$(printf '%s\n' ${entry_array} | fuzzel --index -d)"
(( ${?} != 0 )) && exit