diff --git a/Cargo.lock b/Cargo.lock index f87bb93..c176e3d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -272,7 +272,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "aec364a6ee335b23a7e77703100f5103965810f91a9ef6319a004a7e7b8e2b66" dependencies = [ "dirs", - "git2 0.21.0", + "git2", "terminal-prompt", ] @@ -656,7 +656,7 @@ dependencies = [ "dialoguer", "env_logger", "fs-err", - "git2 0.21.0", + "git2", "gix-config", "gix-hash 0.25.0", "heck 0.5.0", @@ -2198,21 +2198,6 @@ dependencies = [ "stable_deref_trait", ] -[[package]] -name = "git2" -version = "0.20.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b88256088d75a56f8ecfa070513a775dd9107f6530ef14919dac831af9cfe2b" -dependencies = [ - "bitflags 2.11.1", - "libc", - "libgit2-sys", - "log", - "openssl-probe 0.1.6", - "openssl-sys", - "url", -] - [[package]] name = "git2" version = "0.21.0" @@ -5615,7 +5600,7 @@ dependencies = [ "convert_case 0.11.0", "dialoguer", "dirs-next 2.0.0", - "git2 0.20.4", + "git2", "human_bytes", "ootle-network", "reqwest 0.12.28", diff --git a/crates/cli/Cargo.toml b/crates/cli/Cargo.toml index a9ccec3..756535a 100644 --- a/crates/cli/Cargo.toml +++ b/crates/cli/Cargo.toml @@ -26,7 +26,7 @@ clap = { version = "4.5.20", features = ["derive", "string", "env"] } convert_case = "0.11.0" dialoguer = { version = "0.12.0", features = ["default", "fuzzy-select"] } dirs-next = "2.0.0" -git2 = { version = "^0.20", features = ["default"] } +git2 = { version = "^0.21", features = ["default"] } human_bytes = "0.4.3" reqwest = { version = "0.12", default-features = false, features = ["rustls-tls", "json"] } serde = { workspace = true } diff --git a/crates/cli/src/git/repository.rs b/crates/cli/src/git/repository.rs index 99af052..23529b0 100644 --- a/crates/cli/src/git/repository.rs +++ b/crates/cli/src/git/repository.rs @@ -109,7 +109,7 @@ impl GitRepository { let repo = self.repository()?; let head = repo.head()?; if head.is_branch() { - if let Some(name) = head.name() { + if let Ok(name) = head.name() { Ok(name.to_string().replace("refs/heads/", "")) } else { Err(Error::InvalidBranchName)