dotfiles

:)
git clone https://git.sr.ht/~ashymad/dotfiles
Log | Files | Refs | Submodules | LICENSE

commit 7af60b6a9dac3fd45f11901ec7c7eb49d7ee01c0
parent 530652fbc1ba7d9ab31f9ee88305db29e3698d91
Author: Szymon Mikulicz <szymon.mikulicz@posteo.net>
Date:   Sat,  3 Aug 2019 21:46:41 +0200

Add ddcutil brightness controls from SKRADAK to master

Diffstat:
Ai3/.i3/brightness.sh | 7+++++++
Mi3/.i3/config | 20+++++++++++++++++++-
2 files changed, 26 insertions(+), 1 deletion(-)

diff --git a/i3/.i3/brightness.sh b/i3/.i3/brightness.sh @@ -0,0 +1,7 @@ +#!/bin/sh + +MON_NMB=2 + +for i in $(seq 1 $MON_NMB); do + while ! ddcutil -d $i setvcp 10 $1; do :; done +done diff --git a/i3/.i3/config b/i3/.i3/config @@ -106,6 +106,24 @@ mode $power_control { } bindsym $mod+n mode $power_control +mode "brightness" { + bindsym grave exec ~/.i3/brightness.sh 00 + bindsym 1 exec ~/.i3/brightness.sh 10 + bindsym 2 exec ~/.i3/brightness.sh 20 + bindsym 3 exec ~/.i3/brightness.sh 30 + bindsym 4 exec ~/.i3/brightness.sh 40 + bindsym 5 exec ~/.i3/brightness.sh 50 + bindsym 6 exec ~/.i3/brightness.sh 60 + bindsym 7 exec ~/.i3/brightness.sh 70 + bindsym 8 exec ~/.i3/brightness.sh 80 + bindsym 9 exec ~/.i3/brightness.sh 90 + bindsym 0 exec ~/.i3/brightness.sh 100 + + bindsym Return mode "default" + bindsym Escape mode "default" +} +bindsym $mod+Shift+b mode "brightness" + new_window pixel 2 gaps inner 10 @@ -119,7 +137,7 @@ bindsym XF86AudioPlay exec --no-startup-id cmus-remote -u bindsym XF86AudioStop exec --no-startup-id cmus-remote -s bindsym XF86AudioNext exec --no-startup-id cmus-remote -n bindsym XF86AudioPrev exec --no-startup-id cmus-remote -r - + # Sreen brightness controls bindsym XF86MonBrightnessUp exec --no-startup-id xbacklight -inc 10 # increase screen brightness bindsym XF86MonBrightnessDown exec --no-startup-id xbacklight -dec 10 # decrease screen brightness