Update i3 colors, add discord settings and weather.sh RD

This commit is contained in:
Shaun Reed 2020-05-03 01:48:15 -04:00
parent b1c6da6563
commit 24739df294
2 changed files with 55 additions and 1 deletions

View File

@ -215,6 +215,10 @@ for_window [class="Bitwarden"] resize set height 600
for_window [class="Bitwarden"] resize set width 800
for_window [class="Bitwarden"] move position center
for_window [class="discord"] floating enable
for_window [class="discord"] resize set height 600
for_window [class="discord"] resize set width 800
for_window [class="discord"] move position center
for_window [class="Wicd-client.py"] floating enable
for_window [class="Wicd-client.py"] resize set height 400
@ -236,6 +240,7 @@ exec --no-startup-id sh ~/.fehbg
exec --no-startup-id xautolock -time 10 -locker blurlock
exec --no-startup-id wicd-client -t
exec --no-startup-id xfce4-power-manager
exec --no-startup-id google-drive-ocamlfuse ~/gdrive
# Application keybinds
@ -376,7 +381,7 @@ exec_always --no-startup-id compton
# Theme colors
# class border backgr. text indic. child_border
client.focused #01e110 #01e110 #80FFF9 #01e110
client.focused #01e110 #01e110 #80FFF9 #FF0100
client.focused_inactive #2F3D44 #2F3D44 #1ABC9C #454948
client.unfocused #000000 #000000 #1ABC9C #000000
client.urgent #CB4B16 #FDF6E3 #1ABC9C #268BD2

49
.local/bin/i3scripts/weather Executable file
View File

@ -0,0 +1,49 @@
#!/usr/bin/env bash
################################
# Shows info about the weather (in Cincinnati) from accuweather.com
#
# TODO: completely rewrite, probably using openweather APIs
# TODO: make location configurable
# TODO: make temperature unit configurable
#
# @return {Number(degrees Fahrenheit)}: Current temperature in Cincinnati
################################
dir=$(dirname $0)
source $dir/util.sh
full=""
short=""
status=0
URL='http://www.accuweather.com/en/us/cincinnati-oh/45212/weather-forecast/350126'
SITE="$(curl -s "$URL")"
weather="$(echo "$SITE" | awk -F\' '/acm_RecentLocationsCarousel\.push/{print $13 }'| head -1)"
temp="$(echo "$SITE" | awk -F\' '/acm_RecentLocationsCarousel\.push/{print $10 }'| head -1)"
if [[ $weather == *thunder* || $weather == *Thunder* ]]; then
icon=""
else
if [[ $weather == *rain* || $weather == *Rain* ]]; then
icon=""
else
if [[ $weather == *snow* || $weather == *Snow* ]]; then
icon="❄"
else
if [[ $weather == *cloud* || $weather == *Cloud* ]]; then
icon=""
else
icon=""
fi
fi
fi
fi
full="$icon $temp°"
short="$temp°"
echo $full
echo $short
exit $status