diff --git a/lib/i3status-rust.nix b/lib/i3status-rust.nix index b603fa3..bfaf15b 100644 --- a/lib/i3status-rust.nix +++ b/lib/i3status-rust.nix @@ -87,37 +87,6 @@ in { }; }; block = [ - { - block = "custom"; - interval = 10; - command = "newsboat-unread-count"; - json = true; - } - { - block = "custom"; - interval = 10; - command = pkgs.writers.writeDash "todo" '' - ${pkgs.todoman}/bin/todo --porcelain | ${pkgs.jq}/bin/jq -r ' - map(select(.due != null)) - | (map(select(.due < now)) | length) as $overdue - | (map(select(.due >= now and .due < now + (60 * 60 * 24))) | length) as $dueToday - | { - icon: "tasks", - text: "\($overdue)+\($dueToday)", - state: ( - if $overdue > 0 then - "Critical" - elif $dueToday == 0 then - "Good" - else - "Info" - end - ) - } - ' - ''; - json = true; - } { block = "weather"; autolocate = true; @@ -164,6 +133,37 @@ in { print("🌅 {} 🌇 {} {} {}".format(sun["sunrise"].strftime("%R"), sun["sunset"].strftime("%R"), moon_phases[closest_phase], round(current_phase, 1))) ''; } + { + block = "custom"; + interval = 10; + command = "newsboat-unread-count"; + json = true; + } + { + block = "custom"; + interval = 10; + command = pkgs.writers.writeDash "todo" '' + ${pkgs.todoman}/bin/todo --porcelain | ${pkgs.jq}/bin/jq -r ' + map(select(.due != null)) + | (map(select(.due < now)) | length) as $overdue + | (map(select(.due >= now and .due < now + (60 * 60 * 24))) | length) as $dueToday + | { + icon: "tasks", + text: "\($overdue)+\($dueToday)", + state: ( + if $overdue > 0 then + "Critical" + elif $dueToday == 0 then + "Good" + else + "Info" + end + ) + } + ' + ''; + json = true; + } { block = "custom"; interval = 5;