From 59ccb727c0f20add1cb347b8e44a1f47d37b709c Mon Sep 17 00:00:00 2001 From: Eric Huss Date: Fri, 18 Feb 2022 12:15:57 -0800 Subject: [PATCH] Update to 1.4.1 --- CONTRIBUTING.md | 34 ++++++++++++++++++++++++++++++++++ Cargo.toml | 4 ++-- README.md | 2 +- git2-curl/Cargo.toml | 2 +- libgit2-sys/Cargo.toml | 2 +- libgit2-sys/lib.rs | 2 +- libgit2-sys/libgit2 | 2 +- src/lib.rs | 2 +- 8 files changed, 42 insertions(+), 8 deletions(-) create mode 100644 CONTRIBUTING.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000000..ceb1de44ce --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,34 @@ +# Contributing + +## Updating libgit2 + +The following steps can be used to update libgit2: + +1. Update the submodule. + There are several ways to go about this. + One way is to go to the `libgit2-sys/libgit2` directory and run `git fetch origin` to download the latest updates, and then check out a specific tag (such as `git checkout v1.4.1`). +2. Update all the references to the version: + * Update [`libgit2-sys/build.rs`](https://github.com/rust-lang/git2-rs/blob/master/libgit2-sys/build.rs). + There is a version probe (search for `cfg.atleast_version`) which should be updated. + * Update the version in + [`libgit2-sys/Cargo.toml`](https://github.com/rust-lang/git2-rs/blob/master/libgit2-sys/Cargo.toml). + Update the metadata portion (the part after the `+`) to match libgit2. + Also bump the Cargo version (the part before the `+`), keeping in mind + if this will be a SemVer breaking change or not. + * Update the dependency version in [`Cargo.toml`](https://github.com/rust-lang/git2-rs/blob/master/Cargo.toml) to match the version in the last step (do not include the `+` metadata). + Also update the version of the `git2` crate itself so it will pick up the change to `libgit2-sys` (also keeping in mind if it is a SemVer breaking release). + * Update the version in [`README.md`](https://github.com/rust-lang/git2-rs/blob/master/README.md) if needed. + * If there was a SemVer-breaking version bump for either library, also update the `html_root_url` attribute in the `lib.rs` of each library. +3. Run tests. + `cargo test -p git2 -p git2-curl` is a good starting point. +4. Run `systest`. + This will validate for any C-level API problems. + Unfortunately `systest` does not work on nightly, so you'll need to use stable. + + `cargo +stable run -p systest` + + The changelog at + can be helpful for seeing what has changed. + The project has recently started labeling API and ABI breaking changes with labels: + +4. Once you have everything functional, publish a PR with the updates. diff --git a/Cargo.toml b/Cargo.toml index 2f5a415a86..a29bdee5f2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "git2" -version = "0.13.25" +version = "0.14.0" authors = ["Josh Triplett ", "Alex Crichton "] license = "MIT/Apache-2.0" readme = "README.md" @@ -20,7 +20,7 @@ url = "2.0" bitflags = "1.1.0" libc = "0.2" log = "0.4.8" -libgit2-sys = { path = "libgit2-sys", version = "0.12.26" } +libgit2-sys = { path = "libgit2-sys", version = "0.13.0" } [target."cfg(all(unix, not(target_os = \"macos\")))".dependencies] openssl-sys = { version = "0.9.0", optional = true } diff --git a/README.md b/README.md index 6ee6c3c179..b4ea1819eb 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ stable release as well. ## Version of libgit2 -Currently this library requires libgit2 1.4.0. The source for libgit2 is +Currently this library requires libgit2 1.4. The source for libgit2 is included in the libgit2-sys crate so there's no need to pre-install the libgit2 library, the libgit2-sys crate will figure that and/or build that for you. diff --git a/git2-curl/Cargo.toml b/git2-curl/Cargo.toml index 6b68488e3d..e85de4cde4 100644 --- a/git2-curl/Cargo.toml +++ b/git2-curl/Cargo.toml @@ -16,7 +16,7 @@ edition = "2018" curl = "0.4.33" url = "2.0" log = "0.4" -git2 = { path = "..", version = "0.13", default-features = false } +git2 = { path = "..", version = "0.14", default-features = false } [dev-dependencies] civet = "0.11" diff --git a/libgit2-sys/Cargo.toml b/libgit2-sys/Cargo.toml index fab3dbf868..68fc36a4be 100644 --- a/libgit2-sys/Cargo.toml +++ b/libgit2-sys/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "libgit2-sys" -version = "0.12.26+1.4.0" +version = "0.13.0+1.4.1" authors = ["Josh Triplett ", "Alex Crichton "] links = "git2" build = "build.rs" diff --git a/libgit2-sys/lib.rs b/libgit2-sys/lib.rs index 760e966f90..d23c3ec4ff 100644 --- a/libgit2-sys/lib.rs +++ b/libgit2-sys/lib.rs @@ -1,4 +1,4 @@ -#![doc(html_root_url = "https://docs.rs/libgit2-sys/0.12")] +#![doc(html_root_url = "https://docs.rs/libgit2-sys/0.13")] #![allow(non_camel_case_types, unused_extern_crates)] // This is required to link libz when libssh2-sys is not included. diff --git a/libgit2-sys/libgit2 b/libgit2-sys/libgit2 index 1d5b9bd86d..fdd15bcfca 160000 --- a/libgit2-sys/libgit2 +++ b/libgit2-sys/libgit2 @@ -1 +1 @@ -Subproject commit 1d5b9bd86dccc7347aaadf5e3ab122eed9413404 +Subproject commit fdd15bcfca6b2ec4b7ecad1aa11a396cb15bd064 diff --git a/src/lib.rs b/src/lib.rs index 1ba08d21de..60cfc3e071 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -65,7 +65,7 @@ //! source `Repository`, to ensure that they do not outlive the repository //! itself. -#![doc(html_root_url = "https://docs.rs/git2/0.13")] +#![doc(html_root_url = "https://docs.rs/git2/0.14")] #![allow(trivial_numeric_casts, trivial_casts)] #![deny(missing_docs)] #![warn(rust_2018_idioms)]