Merge pull request #71 from zethra/master

Fix bug #70
This commit is contained in:
Ethan Edwards 2020-09-12 21:01:41 -04:00 committed by GitHub
commit cbf738b183
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 10 additions and 1 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
data/weather.txt

0
data/.gitkeep Normal file
View file

View file

@ -1 +0,0 @@
Loading...

View file

@ -104,6 +104,11 @@ main()
# status bar
tmux set-option -g status-style "bg=${gray},fg=${white}"
# wait unit data/weather.txt exists just to avoid errors
# this should almost never need to wait unless something unexpected occurs
while [ ! -f $current_dir/../data/weather.txt ]; do
sleep 0.01
done
# Powerline Configuration
if $show_powerline; then

View file

@ -19,6 +19,10 @@ main()
current_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
if [ ! -f $current_dir/../data/weather.txt ]; then
printf "Loading..." > $current_dir/../data/weather.txt
fi
$current_dir/weather.sh > $current_dir/../data/weather.txt
while tmux has-session &> /dev/null