scripts reorganize
This commit is contained in:
38
scripts/WMScripts/toggle_audiocables.sh
Executable file
38
scripts/WMScripts/toggle_audiocables.sh
Executable file
@@ -0,0 +1,38 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# This script updates the clementine and combine toggle custom modules of my specific polybar setup
|
||||
case "$XDG_CURRENT_DESKTOP" in
|
||||
"sway"|"Hyprland")
|
||||
case "$1" in
|
||||
"clementine")
|
||||
"$(dirname "$0")/toggle_audiocables_bar.sh" toggle clementine
|
||||
kill -37 $(pgrep waybar)
|
||||
;;
|
||||
"combine")
|
||||
"$(dirname "$0")/toggle_audiocables_bar.sh" toggle combine
|
||||
kill -37 $(pgrep waybar)
|
||||
;;
|
||||
*)
|
||||
echo "Unknown sink specified."
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
"i3")
|
||||
case "$1" in
|
||||
"clementine")
|
||||
polybar-msg -p "$(xdotool search --name polybar-default getwindowpid)" action "#audiocables.hook.0"
|
||||
;;
|
||||
"combine")
|
||||
polybar-msg -p "$(xdotool search --name polybar-default getwindowpid)" action "#audiocables.hook.1"
|
||||
;;
|
||||
*)
|
||||
echo "unknown sink specified."
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
*)
|
||||
dunstify -u low -t 2000 -i ~/.icons/candy-icons/apps/scalable/pavucontrol.svg "Current desktop is not supported by audiocables.sh"
|
||||
exit
|
||||
;;
|
||||
esac
|
||||
|
||||
Reference in New Issue
Block a user