Clean up configs, remove bashrc conflicting with bash

This commit is contained in:
natemaia
2017-11-30 22:21:33 -08:00
parent 15fcfc4da1
commit eb0884e453
272 changed files with 7464 additions and 1239 deletions

28
home/bin/toggle-redshift Executable file
View File

@ -0,0 +1,28 @@
#!/usr/bin/env bash
if [[ $1 = "--toggle" ]] || [[ $1 = "-t" ]]; then
if pgrep redshift > /dev/null 2>&1; then
killall redshift
else
redshift &
fi
fi
icon=""
pgrep -x redshift &> /dev/null
if [[ $? -eq 0 ]]; then
temp=$(redshift -p 2>/dev/null | grep temp | cut -d' ' -f3)
temp=${temp//K/}
fi
if [[ -z $temp ]]; then
echo " $icon " # Greyed out (not running)
elif [[ $temp -ge 5000 ]]; then
echo "%{F#8039A0} $icon " # Blue
elif [[ $temp -ge 4000 ]]; then
echo "%{F#F203F0} $icon " # Yellow
else
echo "%{F#FF5B6C} $icon " # Orange
fi