DashNix/eww_laptop/scripts/audio_devices

31 lines
1.9 KiB
Bash
Executable file

#!/bin/bash
CLIENTS=$(pactl list sink-inputs | grep "application.process.binary" | awk -F '= ' ' { print $2 } ' | tr -d '"')
readarray -t lines <<<"$CLIENTS"
printf "%s\n" "${lines[@]}"
echo ${lines[2]}
#echo "(box :class \"works\" :orientation \"h\" :spacing 5 :space-evenly \"false\" (button :onclick \"hyprctl dispatch workspace 1\" :class \"$un$o1$f1\" \"$ic_1\") (button :onclick \"hyprctl dispatch workspace 2\" :class \"$un$o2$f2\" \"$ic_2\") (button :onclick \"hyprctl dispatch workspace 3\" :class \"$un$o3$f3\" \"$ic_3\") (button :onclick \"hyprctl dispatch workspace 4\" :class \"$un$o4$f4\" \"$ic_4\") (button :onclick \"hyprctl dispatch workspace 5\" :class \"$un$o5$f5\" \"$ic_5\") (button :onclick \"hyprctl dispatch workspace 6\" :class \"$un$o6$f6\" \"$ic_6\") (button :onclick \"hyprctl dispatch workspace 7\" :class \"$un$o7$f7\" \"$ic_7\") (button :onclick \"hyprctl dispatch workspace 8\" :class \"$un$o8$f8\" \"$ic_8\"))"
# (eventbox :onhover "scripts/pop hoverCreate"
# :onhoverlost "scripts/pop hoverGet audio_ctl"
# (box :class "audio-box" :orientation "v" :space-evenly "false" :vexpand "false" :hexpand "false"
# (box :halign "center" :space-evenly "false" :hexpand "false" :vexpand "false"
# (box :class "speaker_icon" :orientation "v")
# (box :orientation "v" :halign "center" :vexpand "false" :hexpand "false"
# (label :class "speaker_text" :text "speaker" :valign "center" :halign "left" )
# (box :class "speaker_bar" :halign "center" :vexpand "false" :hexpand "false"
# (scale :value volume_percent
# :space-evenly "false"
# :orientation "h"
# :onchange "pactl set-sink-volume @DEFAULT_SINK@ {}%"
# :tooltip "volume on ${volume_percent}%"
# :max 100
# :min 0))))
# (label :text "" :class "audio_sep" :halign "center")
# ))))