diff options
author | lassulus <lassulus@lassul.us> | 2020-03-23 13:05:55 +0100 |
---|---|---|
committer | lassulus <lassulus@lassul.us> | 2020-03-23 13:05:55 +0100 |
commit | e2ef8aba938fb39f826014de919471c7ce751d83 (patch) | |
tree | 6364a80d4c144a73c14beb60a18c2b37d2ddc04f /krebs | |
parent | e4816a16f9144f4267856f87aa2879fff277730d (diff) |
fetch clouds only every 3h
Diffstat (limited to 'krebs')
-rw-r--r-- | krebs/5pkgs/simple/realwallpaper/default.nix | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/krebs/5pkgs/simple/realwallpaper/default.nix b/krebs/5pkgs/simple/realwallpaper/default.nix index 62d88e1e9..f81f96efe 100644 --- a/krebs/5pkgs/simple/realwallpaper/default.nix +++ b/krebs/5pkgs/simple/realwallpaper/default.nix @@ -77,7 +77,10 @@ pkgs.writers.writeDashBin "generate-wallpaper" '' fetch marker.json "$marker_url" & wait - ${pkgs.nomads-cloud}/bin/nomads-cloud clouds-raw.png + # fetch clouds if they are older than 3h + if ! test "$(find clouds-raw.png -mmin -180)"; then + ${pkgs.nomads-cloud}/bin/nomads-cloud clouds-raw.png + fi check_type nightmap-raw.jpg image check_type daymap-raw.png image |