aboutsummaryrefslogtreecommitdiff
path: root/bin/brightness
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2023-02-17 15:36:29 -0300
committerEuAndreh <eu@euandre.org>2023-02-17 15:36:29 -0300
commit0a345459825bc7edb1363d86d327c10528da9e29 (patch)
tree2c02785a9517d99b1f1b06699bfad6ca5f089362 /bin/brightness
parentetc/nix/configuration.nix: Lock after 5 minutes via logind (diff)
downloaddotfiles-0a345459825bc7edb1363d86d327c10528da9e29.tar.gz
dotfiles-0a345459825bc7edb1363d86d327c10528da9e29.tar.xz
Remove all code referring to backlight tweaking
Diffstat (limited to '')
-rwxr-xr-xbin/brightness12
1 files changed, 0 insertions, 12 deletions
diff --git a/bin/brightness b/bin/brightness
deleted file mode 100755
index 10bd1987..00000000
--- a/bin/brightness
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/bin/sh
-set -eu
-
-BRIGHTNESS_DIFF="$1"
-
-HANDLER=/sys/class/backlight/"$BACKLIGHT_DEVICE"
-
-OLD_BRIGHTNESS="$(cat "$HANDLER"/brightness)"
-MAX_BRIGHTNESS="$(cat "$HANDLER"/max_brightness)"
-SUM=$((OLD_BRIGHTNESS + BRIGHTNESS_DIFF))
-NEW_BRIGHTNESS="$(clamp -- "$SUM" 0 "$MAX_BRIGHTNESS")"
-echo "$NEW_BRIGHTNESS" > "$HANDLER"/brightness || sudo chmod 666 "$HANDLER"/brightness