Updated depedencies

master
Wynd 2025-01-19 00:46:02 +02:00
parent 8084309af5
commit 1d48f9ffc5
5 changed files with 627 additions and 262 deletions

3
.gitignore vendored
View File

@ -1,2 +1,3 @@
/target
profile.json
profile.json
perf.data*

864
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -21,12 +21,11 @@ bench = false
unsafe_code = { level = "forbid" }
[dependencies]
gix = { version = "0.66.0", default-features = false, features = ["mailmap"] }
clap = { version = "4.5.20", features = ["derive"] }
chrono = { version = "0.4.38" }
itertools = { version = "0.13.0" }
anyhow = { version = "1.0.89" }
rayon = { version = "1.10.0" }
gix = { version = "0.70.0", default-features = false, features = ["mailmap"] }
clap = { version = "4.5.26", features = ["derive"] }
chrono = { version = "0.4.39" }
itertools = { version = "0.14.0" }
anyhow = { version = "1.0.95" }
[dev-dependencies]
divan = { version = "0.1.17" }

View File

@ -1,7 +1,7 @@
use std::sync::OnceLock;
use chrono::{Local, NaiveDate};
use gix::{features::hash::Sha1, ObjectId};
use gix::ObjectId;
use libgitheatmap::{
heatmap::{self, Heatmap},
Commit,
@ -12,7 +12,7 @@ static COMMITS: OnceLock<Vec<Commit>> = OnceLock::new();
fn main() {
let mut commits: Vec<Commit> = vec![];
for _n in 0..1000 {
let id = ObjectId::Sha1(Sha1::default().digest());
let id = ObjectId::Sha1([0u8; 20]);
let title = mockd::words::sentence(10);
let author = mockd::name::full();
let email = mockd::contact::email();

View File

@ -11,7 +11,9 @@ use anyhow::anyhow;
use chrono::{DateTime, Duration, Local, NaiveDate, NaiveTime, TimeZone};
use clap::Parser;
use cli::CliArgs;
use gix::{bstr::ByteSlice, traverse::commit::simple::Sorting, ObjectId};
use gix::{
bstr::ByteSlice, revision::walk::Sorting, traverse::commit::simple::CommitTimeOrder, ObjectId,
};
use heatmap::{ColorLogic, HeatmapColors};
use itertools::Itertools;
use mailmap::Mailmap;
@ -185,7 +187,8 @@ pub fn get_commits(
.single()
.unwrap()
.ancestors()
.sorting(Sorting::ByCommitTimeNewestFirstCutoffOlderThan {
.sorting(Sorting::ByCommitTimeCutoff {
order: CommitTimeOrder::NewestFirst,
seconds: start_date.timestamp(),
})
.all()?;