From d94410a6782a2ac52dde2708fcadf9cbddfd8f93 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bla=C5=BE=20Hrastnik?= Date: Mon, 28 Jun 2021 13:08:38 +0900 Subject: [PATCH] Sort the files in descending order --- helix-term/src/ui/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/helix-term/src/ui/mod.rs b/helix-term/src/ui/mod.rs index 2a4d246d..2d4cf9cf 100644 --- a/helix-term/src/ui/mod.rs +++ b/helix-term/src/ui/mod.rs @@ -106,7 +106,7 @@ pub fn file_picker(root: PathBuf) -> Picker { files.take(MAX).collect() }; - files.sort_by_key(|file| file.1); + files.sort_by_key(|file| std::cmp::Reverse(file.1)); let files = files.into_iter().map(|(path, _)| path).collect();