diff options
| author | prabinpanta0 <pantaprabin30@gmail.com> | 2025-10-27 10:35:13 +0545 |
|---|---|---|
| committer | prabinpanta0 <pantaprabin30@gmail.com> | 2025-10-27 10:35:13 +0545 |
| commit | 7275b5f73ff6c1164cba645a5f41ac088a10e7cc (patch) | |
| tree | 1a3c58855f33381489114d69eba13ee0bb4e2476 /config | |
| parent | 95b85dd6c59620d660ff320a07bdf7b3c42bdc46 (diff) | |
config(hypr): run Weather.sh at startup; lower weather cache TTL to 5 minutes
Diffstat (limited to 'config')
| -rw-r--r-- | config/hypr/UserConfigs/Startup_Apps.conf | 3 | ||||
| -rwxr-xr-x | config/hypr/UserScripts/Weather.py | 2 |
2 files changed, 4 insertions, 1 deletions
diff --git a/config/hypr/UserConfigs/Startup_Apps.conf b/config/hypr/UserConfigs/Startup_Apps.conf index 738eb2da..976208e9 100644 --- a/config/hypr/UserConfigs/Startup_Apps.conf +++ b/config/hypr/UserConfigs/Startup_Apps.conf @@ -47,6 +47,9 @@ exec-once = $UserScripts/RainbowBorders.sh # Starting hypridle to start hyprlock exec-once = hypridle +# Weather script to populate cache on startup +exec-once = $UserScripts/Weather.sh + # Here are list of features available but disabled by default # exec-once = swww-daemon --format xrgb && swww img $HOME/Pictures/wallpapers/mecha-nostalgia.png # persistent wallpaper diff --git a/config/hypr/UserScripts/Weather.py b/config/hypr/UserScripts/Weather.py index 3b58d8ff..47c88d1f 100755 --- a/config/hypr/UserScripts/Weather.py +++ b/config/hypr/UserScripts/Weather.py @@ -57,7 +57,7 @@ class WeatherData: CACHE_DIR: Path = Path.home() / ".cache" API_CACHE_PATH: Path = CACHE_DIR / "open_meteo_cache.json" SIMPLE_TEXT_CACHE_PATH: Path = CACHE_DIR / ".weather_cache" -CACHE_TTL_SECONDS = int(os.getenv("WEATHER_CACHE_TTL", "600")) # default 10 minutes +CACHE_TTL_SECONDS = int(os.getenv("WEATHER_CACHE_TTL", "300")) # default 5 minutes # Units: metric or imperial (default metric) UNITS = os.getenv("WEATHER_UNITS", "metric").strip().lower() # metric|imperial |
