Deterministic order of contributors

This commit is contained in:
Laurenz 2023-04-21 12:27:47 +02:00
parent a4075f8b9b
commit 2fbb14f712
2 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ unscanny = "0.1"
include_dir = "0.7" include_dir = "0.7"
pulldown-cmark = "0.9" pulldown-cmark = "0.9"
comemo = "0.2.2" comemo = "0.2.2"
serde = "1" serde = { version = "1", features = ["derive"] }
serde_yaml = "0.8" serde_yaml = "0.8"
heck = "0.4" heck = "0.4"
yaml-front-matter = "0.1" yaml-front-matter = "0.1"

View File

@ -38,7 +38,7 @@ pub fn contributors(from: &str, to: &str) -> Option<Html> {
.collect(); .collect();
// Sort by highest number of commits. // Sort by highest number of commits.
contributors.sort_by_key(|c| Reverse(c.contributions)); contributors.sort_by_key(|c| (Reverse(c.contributions), c.login.clone()));
if contributors.is_empty() { if contributors.is_empty() {
return None; return None;
} }