git-branchless: 0.10.0 -> 0.11.0 (#523251)

This commit is contained in:
Niklas Hambüchen
2026-05-25 12:09:01 +00:00
committed by GitHub
2 changed files with 3 additions and 35 deletions
@@ -1,18 +0,0 @@
diff --git a/src/lock.rs b/src/lock.rs
--- a/src/lock.rs
+++ b/src/lock.rs
@@ -132,10 +132,10 @@ impl ScopedDirLock {
// Lock
match (opts.exclusive, opts.non_blocking) {
- (true, false) => file.lock_exclusive(),
- (true, true) => file.try_lock_exclusive(),
- (false, false) => file.lock_shared(),
- (false, true) => file.try_lock_shared(),
+ (true, false) => fs2::FileExt::lock_exclusive(&file),
+ (true, true) => fs2::FileExt::try_lock_exclusive(&file),
+ (false, false) => fs2::FileExt::lock_shared(&file),
+ (false, true) => fs2::FileExt::try_lock_shared(&file),
}
.context(&path, || {
format!(
+3 -17
View File
@@ -13,30 +13,16 @@
rustPlatform.buildRustPackage (finalAttrs: {
pname = "git-branchless";
version = "0.10.0";
version = "0.11.0";
src = fetchFromGitHub {
owner = "arxanas";
repo = "git-branchless";
rev = "v${finalAttrs.version}";
hash = "sha256-8uv+sZRr06K42hmxgjrKk6FDEngUhN/9epixRYKwE3U=";
hash = "sha256-mxZLS39/QNDSR3RZsG17Sd+ses3IEqtbqIMASxOpzmo=";
};
# Patch the vendored esl01-indexedlog crate.
# This is necessary to fix the build for rust 1.89. See:
# - https://github.com/NixOS/nixpkgs/issues/437051
# - https://github.com/arxanas/git-branchless/issues/1585
# - https://github.com/facebook/sapling/issues/1119
# The patch is derived from:
# - https://github.com/facebook/sapling/commit/9e27acb84605079bf4e305afb637a4d6801831ac
postPatch = ''
(
cd $cargoDepsCopy/*/esl01-indexedlog-*/
patch -p1 < ${./fix-esl01-indexedlog-for-rust-1_89.patch}
)
'';
cargoHash = "sha256-i7KpTd4fX3PrhDjj3R9u98rdI0uHkpQCxSmEF+Gu7yk=";
cargoHash = "sha256-bAZ0M3/RD3L+x0Xb+n6XPn0wRj+bQkoOmErSDuOHIRw=";
nativeBuildInputs = [ pkg-config ];