Files
linux-config/configs/i3blocks-scripts/backlight
Kevin Mok c87546e75c Copied i3blocks scripts from orig dir
Some were modified from original but can't be bothered to check which.
'backlight' is custom. Changed both PC/laptop i3blocks config to
reference new i3blocks-scripts location.

system: Fixed keyboard repeat rate for PC/laptop.
Git: Added amending commit and forcing push aliases.
i3: Changed '$mod+F[1-3]' mappings to just 'F[1-3]'.
2018-03-08 06:48:01 -05:00

10 lines
191 B
Bash
Executable File

#!/bin/sh
# https://askubuntu.com/a/179949/794515
round()
{
echo $(printf %.$2f $(echo "scale=$2;(((10^$2)*$1)+0.5)/(10^$2)" | bc))
};
cur_bl=$(xbacklight -get)
echo "$(round "$cur_bl" 0)%"