mirror of
https://github.com/kmein/niveum
synced 2026-03-16 18:21:07 +01:00
feat(i3status-rust): reorder
This commit is contained in:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user