rust-lang/git2-rs
libgit2 bindings for Rust observed · 2026-08-28
Health v2 · maintenance only
76/100
- Activity 98
- Release rhythm 35
- Longevity 100
Flags: no_releases
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-03. Adoption (stars, forks) is never an input.
- gap_med: n/a
- age_days: 4415
- days_rel: n/a
- days_push: 12
- n_releases_24m: 0
Adoption not part of the score
2090 stars · 451 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
git2-rs provides safe, idiomatic Rust bindings to the libgit2 C library for reading and writing git repositories. It offers automatic resource management, strong typing, and optional HTTPS/SSH network support via feature flags.
Use cases
- programmatically read and write git repositories from Rust
- clone remote git repositories in a Rust application
- build a custom git client or tooling in Rust
- inspect commits, branches, and refs without shelling out to git
- embed git functionality in a Rust CLI or service
When to choose
- you need fast, in-process git operations in Rust without invoking the git binary
- you want memory-safe, threadsafe bindings with automatic resource management
- you need fine-grained control over repository internals like objects, refs, and diffs
When to avoid
- you just need to run simple git commands - shelling out to the git CLI may be simpler
- you need every libgit2 API - some bindings are still missing
- you want a pure-Rust implementation without C dependencies - consider gitoxide instead
Facets
library · maturity stable
version-control developer-tools sdk version-control developer-tools cross-platform rust cross-platform windows libgit2 git bindings ffi cargo-crate linux macos
10 sources
- readme: https://github.com/rust-lang/git2-rs · fetched 2026-08-28 · 13a9b338c79d
- homepage: https://docs.rs/git2 · fetched 2026-08-29 · 87598de58262
- site_page: https://docs.rs/ · fetched 2026-08-29 · 602d3d4df413
- site_page: https://docs.rs/crate/git2/latest · fetched 2026-08-29 · 3c99ff97e44b
- site_page: https://docs.rs/crate/git2/latest/features · fetched 2026-08-29 · 17ea162691c1
- site_page: https://docs.rs/about · fetched 2026-08-29 · 29ab7986fbf5
- site_page: https://docs.rs/about/badges · fetched 2026-08-29 · 6588cac258af
- site_page: https://docs.rs/about/builds · fetched 2026-08-29 · 811231ca4680
- site_page: https://docs.rs/about/metadata · fetched 2026-08-29 · 0dcdccb2b2b2
- site_page: https://docs.rs/about/redirections · fetched 2026-08-29 · 1b1efd93105f
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| rust-lang/git2-rs | main | 76 |
For agents
markdown · JSON · MCP: product_card(name="rust-lang/git2-rs")
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem