From 08845cec6393482a60493e465f0ba13727386f5b Mon Sep 17 00:00:00 2001 From: David Runge Date: Sun, 8 May 2016 20:22:16 +0200 Subject: bin/set_volume: Making script not depend on functions.sh anymore. Introducing bash strict mode. --- bin/brightness | 23 ----------------------- 1 file changed, 23 deletions(-) delete mode 100755 bin/brightness (limited to 'bin/brightness') diff --git a/bin/brightness b/bin/brightness deleted file mode 100755 index 192dc4c..0000000 --- a/bin/brightness +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash -# Script to lower/ raise screen brightness using xbacklight (xorg-xbacklight) - -set -e -u - -export DISPLAY=:0 -x11user=$(w |grep -w :0 | cut -d " " -f1) -export XAUTHORITY=/home/$x11user/.Xauthority -step=5 - -if [ -x /usr/bin/xbacklight ]; then - if [ "$1" = "video/brightnessup" ] && [ $2 = "BRTUP" ]; then - xbacklight -inc "$step" - elif [ "$1" = "video/brightnessdown" ] && [ $2 = "BRTDN" ]; then - xbacklight -dec "$step" - else - exit 1 - fi -else - exit 1 -fi - -exit 0 -- cgit v1.2.3-70-g09d2