tmux-kanagawa/sleep_weather.sh
Dane Williams 7e3da16262 tructus
2020-03-15 11:49:00 -07:00

20 lines
427 B
Bash
Executable file

#/usr/bin/env bash
#wrapper script for running weather on interval
main()
{
while tmux has-session &> /dev/null
do
./weather.sh > ~/.tmux/plugins/tmux-dracula/weather.txt
# error=$(cat ~/.tmux/plugins/tmux-dracula/weather.txt | sed -n 2p)
# if [ $error = ' "error": {' ]; then
# echo "Too Many Requests" > ~/.tmux/plugins/tmux-dracula/weather.txt
# break
# fi
sleep 1000
done
}
#run main driver function
main