From 3c03ece72d41d1e3f4fefdcde567ca2f37b36bad Mon Sep 17 00:00:00 2001 From: figsoda Date: Thu, 23 Mar 2023 16:04:03 -0400 Subject: [PATCH] git-dive: 0.1.4 -> 0.1.5 Diff: https://github.com/gitext-rs/git-dive/compare/v0.1.4...v0.1.5 Changelog: https://github.com/gitext-rs/git-dive/blob/v0.1.5/CHANGELOG.md --- .../version-management/git-dive/default.nix | 29 +++++++++++++++---- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/pkgs/applications/version-management/git-dive/default.nix b/pkgs/applications/version-management/git-dive/default.nix index 78963ec05e95..06cf6b3c28a4 100644 --- a/pkgs/applications/version-management/git-dive/default.nix +++ b/pkgs/applications/version-management/git-dive/default.nix @@ -4,21 +4,25 @@ , pkg-config # libgit2-sys doesn't support libgit2 1.6 yet , libgit2_1_5 +, oniguruma , zlib +, stdenv +, darwin +, git }: rustPlatform.buildRustPackage rec { pname = "git-dive"; - version = "0.1.4"; + version = "0.1.5"; src = fetchFromGitHub { owner = "gitext-rs"; repo = "git-dive"; rev = "v${version}"; - hash = "sha256-nl6JEVOU5eDntPOItYCooBi3zx2ceyRLtelr97uYiOY="; + hash = "sha256-LOvrPId/GBWPq73hdCdaMNKH7K7cmGmlkepkQiwGC60="; }; - cargoHash = "sha256-johUvl2hPlgn+2wgFJUR6/pR7lx1NzE4ralcjhVqkik="; + cargoHash = "sha256-JDybjIUjj9ivJ5hJJB9bvGB18TdwEXQZfKfXPkyopK0="; nativeBuildInputs = [ pkg-config @@ -26,16 +30,31 @@ rustPlatform.buildRustPackage rec { buildInputs = [ libgit2_1_5 + oniguruma zlib + ] ++ lib.optionals stdenv.isDarwin [ + darwin.apple_sdk.frameworks.Security ]; + nativeCheckInputs = [ + git + ]; + + # don't use vendored libgit2 + buildNoDefaultFeatures = true; + checkFlags = [ # requires internet access "--skip=screenshot" ]; - # don't use vendored libgit2 - buildNoDefaultFeatures = true; + preCheck = '' + export HOME=$(mktemp -d) + git config --global user.name nixbld + git config --global user.email nixbld@example.com + ''; + + RUSTONIG_SYSTEM_LIBONIG = true; meta = with lib; { description = "Dive into a file's history to find root cause";