summaryrefslogtreecommitdiff
path: root/mprisctl
diff options
context:
space:
mode:
authorzachir <zachir@librem.one>2023-08-06 22:55:00 -0500
committerzachir <zachir@librem.one>2023-08-06 22:55:00 -0500
commitb49fbd12bd77f379fc1bf466531dec20658f7540 (patch)
tree3ec9bc9c881811567d11d1a728c7021987120dcf /mprisctl
parenteaf278d39aa7f7a322bdb21feb6af9ea5a5bf9df (diff)
Fully replace bemenu with tofi
Diffstat (limited to 'mprisctl')
-rwxr-xr-xmprisctl8
1 files changed, 5 insertions, 3 deletions
diff --git a/mprisctl b/mprisctl
index 0685de7..ce03642 100755
--- a/mprisctl
+++ b/mprisctl
@@ -6,7 +6,7 @@ printhelp () {
while getopts "hwxd:" o; do case "${o}" in
w)
- DMENU="bemenu"
+ DMENU="tofi"
;;
x)
DMENU="dmenu"
@@ -17,16 +17,18 @@ esac done
if [ -z "$DMENU" ]; then
if [ -n "$WAYLAND_DISPLAY" ]; then
- DMENU="bemenu"
+ DMENU="tofi"
+ DEFARGS="--prompt-text"
elif [ -n "$DISPLAY" ]; then
DMENU="dmenu"
+ DEFARGS="-p"
else
printf "Can't tell if Wayland or X; what gives?\n"
exit 1
fi
fi
-DMENU_PROMPT=$(playerctl -l | $DMENU $ARGS -p 'Players:')
+DMENU_PROMPT=$(playerctl -l | $DMENU $ARGS $DEFARGS 'Players:')
[ -z "$DMENU_PROMPT" ] && exit 1
PLAYERCONTROLS_PROMPT=$(echo "play-pause