diff options
| author | marcellus <msimon_fr@hotmail.com> | 2023-06-10 08:50:02 +0200 |
|---|---|---|
| committer | marcellus <msimon_fr@hotmail.com> | 2023-06-10 08:50:02 +0200 |
| commit | f8e2c21e3006cee4aef9456cedab10b3f8f83ad6 (patch) | |
| tree | a3296ce08ca200fbc45ccd55bac33eda514012fd | |
| parent | 462688791c45e97dd94e5ca5b79e54a585228903 (diff) | |
fix: kinda fixed the sxhkdrc to make the brightness work, requires you to export a BRIGHTNESS environment variable. But still, it doesn't really work
| -rwxr-xr-x | scripts/setbrightness | 10 | ||||
| -rw-r--r-- | sxhkd/sxhkdrc | 7 | ||||
| -rw-r--r-- | zsh/.zshenv | 1 | ||||
| -rw-r--r-- | zsh/.zshrc | 3 |
4 files changed, 15 insertions, 6 deletions
diff --git a/scripts/setbrightness b/scripts/setbrightness new file mode 100755 index 0000000..df53b6d --- /dev/null +++ b/scripts/setbrightness @@ -0,0 +1,10 @@ +# ███╗ ███╗ +# author: marcellus <msimon_fr@hotmail.com> ████╗ ████║ +# ██╔████╔██║ +# created: Thu, 08 Jun 2023 21:44:29 +0200 ██║╚██╔╝██║ +# updated: Thu, 08 Jun 2023 23:48:49 +0200 =## . :#%*=:. +# ╚═╝ ╚═╝ + +#!/bin/sh + +xrandr --output eDP-1 --brightness $1 diff --git a/sxhkd/sxhkdrc b/sxhkd/sxhkdrc index a4f7c22..7b7c6b5 100644 --- a/sxhkd/sxhkdrc +++ b/sxhkd/sxhkdrc @@ -1,4 +1,5 @@ -# reload with kill -10 $(pidof sxhkd) +super + Escape + kill -10 $(pidof sxhkd) {super + Return,button8} $TERMINAL super + d @@ -10,9 +11,9 @@ Scroll_Lock Print screenshot XF86MonBrightnessUp - setbrightness $(printf "%.2f" "$(($(xrandr --verbose | awk '/Brightness/ {print $2;exit}') + 0.1))") + BRIGHTNESS=$(($BRIGHTNESS+0.1));setbrightness $BRIGHTNESS XF86MonBrightnessDown - setbrightness $(printf "%.2f" "$(($(xrandr --verbose | awk '/Brightness/ {print $2;exit}') - 0.1))") + BRIGHTNESS=$(($BRIGHTNESS-0.1));setbrightness $BRIGHTNESS XF86AudioRaiseVolume pamixer -i 5; kill -44 $(pidof dwmblocks) XF86AudioLowerVolume diff --git a/zsh/.zshenv b/zsh/.zshenv index 54752cb..eba98af 100644 --- a/zsh/.zshenv +++ b/zsh/.zshenv @@ -2,6 +2,7 @@ export PATH="$HOME/.config/scripts:$PATH" export TERMINAL="st" export EDITOR="nvim" export BROWSER="librewolf" +export BRIGHTNESS=1 export XDG_CONFIG_HOME="$HOME/.config" export XDG_DATA_HOME="$HOME/data" @@ -60,6 +60,3 @@ qc(){ cc "$1" && ./a.out } -setbrightness() { - xrandr --output eDP-1 --brightness $1 -} |
