fix: sort reminders by date in descending order before output
This commit is contained in:
@@ -58,6 +58,7 @@ let ical2rem ical_files =
|
|||||||
good_rems_acc)
|
good_rems_acc)
|
||||||
in
|
in
|
||||||
|
|
||||||
|
let good_rems = List.sort (fun a b -> Timedesc.Date.compare b.Remind.date a.Remind.date) good_rems in
|
||||||
try ListLabels.iter good_rems ~f:(fun rem -> Printf.printf "%s" (Remind.string_of_rem rem))
|
try ListLabels.iter good_rems ~f:(fun rem -> Printf.printf "%s" (Remind.string_of_rem rem))
|
||||||
with e ->
|
with e ->
|
||||||
Printf.eprintf "Error processing reminders: %s\n" (Printexc.to_string e);
|
Printf.eprintf "Error processing reminders: %s\n" (Printexc.to_string e);
|
||||||
|
|||||||
Reference in New Issue
Block a user