fix tmux and other stuff

This commit is contained in:
Noah Masur committed 2020-08-01 20:06:16 -04:00
1 parent a3026b91ba
commit fa5850db16
11 files changed
+117 -103

No files matched your search

+12
View File
@@ -0,0 +1,12 @@
#!/bin/sh
CACHE_FILE="$HOME/.tmux/.weather_cache"
CACHE_TIME=$(stat -f %m $CACHE_FILE)
NOW_TIME=$(date +%s)
TIME_PASSED=$((NOW_TIME-CACHE_TIME))
if [[ "$TIME_PASSED" -gt "1200" ]]
then
curl -m 2 -s wttr.in/\?format\="%c%t" > $CACHE_FILE
fi
cat $CACHE_FILE