From 3ce18805c4d2c712c50c9cd4e007ac21355a2c5c Mon Sep 17 00:00:00 2001 From: Alexander Hosking Date: Fri, 12 May 2017 15:07:44 -0400 Subject: [PATCH] Add Volume info to status bar and add backlight controls --- .i3/config | 14 ++++++++++---- .i3/i3status.conf | 8 ++++++++ 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/.i3/config b/.i3/config index ee19976..e00be22 100755 --- a/.i3/config +++ b/.i3/config @@ -49,10 +49,16 @@ bindsym Control+space exec --no-startup-id i3-dmenu-desktop # installed. # bindsym $mod+d exec --no-startup-id i3-dmenu-desktop -## Volume -bindsym XF86AudioRaiseVolume exec amixer -q set Master 2dB+ unmute -bindsym XF86AudioLowerVolume exec amixer -q set Master 2dB- unmute -bindsym XF86AudioMute exec amixer -q set Master toggle +# Pulse Audio controls +## requires alsa-utils pulseaudio +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl -- set-sink-volume 0 +5% #increase sound volume +bindsym XF86AudioLowerVolume exec --no-startup-id pactl -- set-sink-volume 0 -5% #decrease sound volume +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 0 toggle # mute sound + +# Sreen brightness controls +## requires xbacklight +bindsym XF86MonBrightnessUp exec xbacklight -inc 20 # increase screen brightness +bindsym XF86MonBrightnessDown exec xbacklight -dec 20 # decrease screen brightness # change focus bindsym $mod+h focus left diff --git a/.i3/i3status.conf b/.i3/i3status.conf index 8f4fdd4..99cc28c 100755 --- a/.i3/i3status.conf +++ b/.i3/i3status.conf @@ -12,6 +12,7 @@ general { } #order += "ipv6" +order += "volume master" order += "disk /" #order += "run_watch DHCP" order += "run_watch VPN" @@ -69,3 +70,10 @@ load { disk "/" { format = "%avail" } + +volume master { + format = "♪: %volume" + format_muted = "♪: muted (%volume)" + device = "sysdefault" + mixer = "Master" +}