summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorstreetturtle <streetturtle@users.noreply.github.com>2020-07-14 10:30:35 -0400
committerGitHub <noreply@github.com>2020-07-14 10:30:35 -0400
commit8dd2793651e7822582863bad6a4540bdeb29d6c0 (patch)
tree71c7ead144d80811105c8f7d22e135cb8a273e46
parent72b4a2d4ca47dee6b432531b5f1112f0b90bb429 (diff)
parenta1ebd2af6cc9600060ad63c4957dc4e0976f4834 (diff)
Merge pull request #168 from webknjaz/bugfixes/167-weather-upd-freq
⛅ Decrease weather update frequency to 2 minutes
-rw-r--r--weather-widget/weather.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/weather-widget/weather.lua b/weather-widget/weather.lua
index 4fcdba7..21d3d0d 100644
--- a/weather-widget/weather.lua
+++ b/weather-widget/weather.lua
@@ -450,7 +450,11 @@ local function worker(args)
end)))
-- watch('cat /home/pmakhov/.config/awesome/awesome-wm-widgets/weather-widget/weather.json', 5, update_widget, weather_widget)
- watch(string.format(GET_FORECAST_CMD, owm_one_cal_api), 5, update_widget, weather_widget)
+ watch(
+ string.format(GET_FORECAST_CMD, owm_one_cal_api),
+ 120, -- API limit is 1k req/day; day has 1440 min; every 2 min is good
+ update_widget, weather_widget,
+ )
return weather_widget
end