{"id":13484362,"url":"https://github.com/rust-lang/git2-rs","last_synced_at":"2025-05-14T07:07:58.330Z","repository":{"id":19294309,"uuid":"22531552","full_name":"rust-lang/git2-rs","owner":"rust-lang","description":"libgit2 bindings for Rust","archived":false,"fork":false,"pushed_at":"2025-05-05T17:12:32.000Z","size":3921,"stargazers_count":1842,"open_issues_count":156,"forks_count":413,"subscribers_count":20,"default_branch":"master","last_synced_at":"2025-05-07T07:00:00.362Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://docs.rs/git2","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rust-lang.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2014-08-01T22:30:49.000Z","updated_at":"2025-05-06T08:20:30.000Z","dependencies_parsed_at":"2023-02-15T19:20:35.521Z","dependency_job_id":"558334c9-476e-4f63-a604-2814a19087e9","html_url":"https://github.com/rust-lang/git2-rs","commit_stats":{"total_commits":1359,"total_committers":254,"mean_commits":5.350393700787402,"dds":0.5224429727740987,"last_synced_commit":"7d5c02043a60e24bfb6c42ba488004ab957b82d5"},"previous_names":[],"tags_count":206,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-lang%2Fgit2-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-lang%2Fgit2-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-lang%2Fgit2-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rust-lang%2Fgit2-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rust-lang","download_url":"https://codeload.github.com/rust-lang/git2-rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254077094,"owners_count":22010661,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T17:01:23.045Z","updated_at":"2025-05-14T07:07:58.308Z","avatar_url":"https://github.com/rust-lang.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# git2-rs\n\n[Documentation](https://docs.rs/git2)\n\nlibgit2 bindings for Rust.\n\n```toml\n[dependencies]\ngit2 = \"0.20.2\"\n```\n\n## Rust version requirements\n\ngit2-rs works with stable Rust, and typically works with the most recent prior\nstable release as well.\n\n## Version of libgit2\n\nCurrently this library requires libgit2 1.9.0 (or newer patch versions). The\nsource for libgit2 is included in the libgit2-sys crate so there's no need to\npre-install the libgit2 library, the libgit2-sys crate will figure that and/or\nbuild that for you. On the other hand, if an appropriate version of `libgit2`\nis present, `git2` will attempt to dynamically link it.\n\nTo be more precise, the vendored `libgit2` is linked statically if two\nconditions both hold:\n\n- The environment variable `LIBGIT2_NO_VENDOR=1` is **not** set\n- **and** either a) The Cargo feature `vendored-libgit2` is set or b) an\n  appropriate version of `libgit2` cannot be found on the system.\n\nIn particular, note that the environment variable overrides the Cargo feature.\n\n## Building git2-rs\n\n```sh\n$ git clone https://github.com/rust-lang/git2-rs\n$ cd git2-rs\n$ cargo build\n```\n\n### Automating Testing\n\nRunning tests and handling all of the associated edge cases on every commit\nproves tedious very quickly.  To automate tests and handle proper stashing and\nunstashing of unstaged changes and thus avoid nasty surprises, use the\npre-commit hook found [here][pre-commit-hook] and place it into the\n`.git/hooks/` with the name `pre-commit`.  You may need to add execution\npermissions with `chmod +x`.\n\nTo skip tests on a simple commit or doc-fixes, use `git commit --no-verify`.\n\n## Building on macOS 10.10+\n\nIf the `ssh` feature is enabled (and it is by default) then this library depends\non libssh2 which depends on OpenSSL. To get OpenSSL working follow the\n[`openssl` crate's instructions](https://github.com/sfackler/rust-openssl/blob/master/openssl/src/lib.rs#L31).\n\n# License\n\nThis project is licensed under either of\n\n * Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or\n   https://www.apache.org/licenses/LICENSE-2.0)\n * MIT license ([LICENSE-MIT](LICENSE-MIT) or\n   https://opensource.org/licenses/MIT)\n\nat your option.\n\n### Contribution\n\nUnless you explicitly state otherwise, any contribution intentionally submitted\nfor inclusion in git2-rs by you, as defined in the Apache-2.0 license, shall be\ndual licensed as above, without any additional terms or conditions.\n\n[pre-commit-hook]: https://gist.github.com/glfmn/0c5e9e2b41b48007ed3497d11e3dbbfa\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frust-lang%2Fgit2-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frust-lang%2Fgit2-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frust-lang%2Fgit2-rs/lists"}