Added a mute-unmute script and binding to alt+mute key
This commit is contained in:
parent
ebaa989d7e
commit
5d719984eb
1
i38.sh
1
i38.sh
@ -250,6 +250,7 @@ bindsym Mod1+Control+Delete exec --no-startup-id sgtk-bar
|
|||||||
# Use pactl to adjust volume in PulseAudio.
|
# Use pactl to adjust volume in PulseAudio.
|
||||||
bindsym Mod1+XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10%
|
bindsym Mod1+XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10%
|
||||||
bindsym Mod1+XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10%
|
bindsym Mod1+XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10%
|
||||||
|
bindsym Mod1+XF86AudioMute exec --no-startup-id ${i3Path}/scripts/mute-unmute.sh
|
||||||
|
|
||||||
# Music player controls
|
# Music player controls
|
||||||
# Requires playerctl.
|
# Requires playerctl.
|
||||||
|
8
scripts/mute-unmute.sh
Executable file
8
scripts/mute-unmute.sh
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
if [ $(pamixer --get-mute) = false ]; then
|
||||||
|
spd-say -Cw 'muting'
|
||||||
|
pamixer -t
|
||||||
|
else
|
||||||
|
pamixer -t
|
||||||
|
spd-say -Cw 'unmuted'
|
||||||
|
fi
|
Loading…
Reference in New Issue
Block a user