Shift X2 status from legacy to archived
[khatus.git] / khatus_sensor_screen_brightness.sh
... / ...
CommitLineData
1#! /bin/sh
2
3set -e
4
5screen_brightness_device_path="$1"
6
7awk '
8 BEGIN {
9 OFS = msg_fs ? msg_fs : "|"
10 Kfs = key_fs ? key_fs : ":"
11 }
12
13 FILENAME ~ "/max_brightness$" {max = $1; next}
14 FILENAME ~ "/brightness$" {cur = $1; next}
15 END {print("percentage", (cur / max) * 100)}
16' \
17"$screen_brightness_device_path/max_brightness" \
18"$screen_brightness_device_path/brightness"
This page took 0.03041 seconds and 5 git commands to generate.