From 00e434fd634461e100b23158eeb4cd1f332afbe0 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Thu, 28 May 2026 03:24:34 +0000 Subject: [PATCH] fix(nix): switch from cargoLock to cargoHash to fix crates.io 403 errors The old `cargoLock` approach uses `importCargoLock` which downloads individual crates from the deprecated `crates.io/api/v1/crates` URL that now returns 403 errors. Switching to `cargoHash` uses `fetchCargoVendor` which downloads from `static.crates.io` (the CDN) via the sparse registry protocol, avoiding the deprecated API entirely. --- nix/yazi-unwrapped.nix | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/nix/yazi-unwrapped.nix b/nix/yazi-unwrapped.nix index 3601b485..7145ecb9 100644 --- a/nix/yazi-unwrapped.nix +++ b/nix/yazi-unwrapped.nix @@ -26,12 +26,7 @@ rustPlatform.buildRustPackage (finalAttrs: { pname = "yazi"; inherit version src; - cargoLock = { - lockFile = "${src}/Cargo.lock"; - #outputHashes = { - # "mlua-0.10.0" = "sha256-Xg6/jc+UP8tbJJ6x1sbAgt8ZHt051xEBBcjmikQqYlw="; - #}; - }; + cargoHash = "sha256-EnxhbS+FO3MPKmNkh30x2Wwyf23CgZ/6B+guAwRq32Y="; env = { YAZI_GEN_COMPLETIONS = true;