Add pulseaudio-control

This commit is contained in:
Ethan Lane 2024-08-15 16:20:09 +01:00
parent 613d216572
commit 2f75a8d993
2 changed files with 11 additions and 9 deletions

View file

@ -63,9 +63,10 @@ in {
os-prober
pavucontrol
picom
pm2
plexamp
pm2
polybar
polybar-pulseaudio-control
ranger
rofi
rofi-emoji

View file

@ -53,7 +53,7 @@ font-1 = Font Awesome 6 Free:style=Regular;2
font-2 = Font Awesome 6 Free:style=Solid;2
modules-left = xworkspaces xwindow
modules-right = filesystem audiooutput pulseaudio xkeyboard memory cpu battery date
modules-right = filesystem pulseaudio-control-output xkeyboard memory cpu battery date
cursor-click = pointer
cursor-scroll = ns-resize
@ -114,14 +114,15 @@ label-volume = %percentage%%
label-muted = muted
label-muted-foreground = ${colors.disabled}
[module/audiooutput]
[module/pulseaudio-control-output]
type = custom/script
exec = cat ~/.cache/scripts/get-sink-name.txt
interval = 1
format = <label>
format-prefix = "OUT "
format-prefix-foreground = ${colors.primary}
label = %output%
exec = pulseaudio-control --format 'VOL $VOL_LEVEL%' listen
click-right = exec pavucontrol &
click-left = pulseaudio-control togmute
click-middle = pulseaudio-control next-node
scroll-up = pulseaudio-control --volume-max 100 up
scroll-down = pulseaudio-control --volume-max 100 down
[module/xkeyboard]
type = internal/xkeyboard