myconfigfiles/.config/sway/light.sh

17 lines
332 B
Bash
Executable file

#!/bin/bash
brightness="$(light | sed 's/\.[0-9]*//g')"
if [ "$brightness" -gt "95" ]; then
echo "🌞"
elif [ "$brightness" -gt "75" ]; then
echo "🌕"
elif [ "$brightness" -gt "60" ]; then
echo "🌖"
elif [ "$brightness" -gt "45" ]; then
echo "🌗"
elif [ "$brightness" -gt "15" ]; then
echo "🌘"
else
echo "🌑"
fi