Dotfiles for my tiling window manager + terminal workflow.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

9 lines
191 B

#!/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)%"