Create an executable script which calls the volume function. Hoping it works better with i3 than the function was.

This commit is contained in:
2026-07-23 13:00:28 -07:00
parent 3b1502f6c1
commit a9352773a7
3 changed files with 20 additions and 15 deletions
+9 -9
View File
@@ -166,17 +166,17 @@ bindsym shift+XF86MonBrightnessDown exec --no-startup-id "light -U 20; notify-se
# TBD: Why is the displayed volume not showing up like `light -G` above?
# Use the comma and period keys to change volume.
bindsym $mod+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -5 && notify-send "Volume -" $(vol-d)'
bindsym $mod+period exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +5 && notify-send 'Volume +' $(vol-d)"
bindsym shift+$mod+comma exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume -25 && notify-send 'Volume ---' $(vol-d)"
bindsym shift+$mod+period exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +25 && notify-send 'Volume +++' $(vol-d)"
bindsym $mod+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -5 && notify-send "Volume -" $(volume)'
bindsym $mod+period exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +5 && notify-send 'Volume +' $(volume)"
bindsym shift+$mod+comma exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume -25 && notify-send 'Volume ---' $(volume)"
bindsym shift+$mod+period exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +25 && notify-send 'Volume +++' $(volume)"
# Actual volume keys.
bindsym XF86AudioMute exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume mute && notify-send 'Volume Muted' $(vol-d)"
bindsym XF86AudioRaiseVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +5 && notify-send 'Volume +' $(vol-d)"
bindsym XF86AudioLowerVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume -5 && notify-send 'Volume -' $(vol-d)"
bindsym shift+XF86AudioRaiseVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +25 && notify-send 'Volume +++' $(vol-d)"
bindsym shift+XF86AudioLowerVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume -25 && notify-send 'Volume ---' $(vol-d)"
bindsym XF86AudioMute exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume mute && notify-send 'Volume Muted' $(volume)"
bindsym XF86AudioRaiseVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +5 && notify-send 'Volume +' $(volume)"
bindsym XF86AudioLowerVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume -5 && notify-send 'Volume -' $(volume)"
bindsym shift+XF86AudioRaiseVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume +25 && notify-send 'Volume +++' $(volume)"
bindsym shift+XF86AudioLowerVolume exec --no-startup-id bash -c "source /usr/local/bin/volume.function && volume -25 && notify-send 'Volume ---' $(volume)"
# Define names for default workspaces for which we configure key bindings later on.