diff options
Diffstat (limited to 'pkgs/shells/nushell/plugins/gstat.nix')
-rw-r--r-- | pkgs/shells/nushell/plugins/gstat.nix | 27 |
1 files changed, 17 insertions, 10 deletions
diff --git a/pkgs/shells/nushell/plugins/gstat.nix b/pkgs/shells/nushell/plugins/gstat.nix index f7e912a6fdc..10ab89368a8 100644 --- a/pkgs/shells/nushell/plugins/gstat.nix +++ b/pkgs/shells/nushell/plugins/gstat.nix @@ -5,25 +5,32 @@ , nushell , pkg-config , Security +, nix-update-script }: -let +rustPlatform.buildRustPackage rec { pname = "nushell_plugin_gstat"; -in -rustPlatform.buildRustPackage { - inherit pname; - version = "0.85.0"; - src = nushell.src; - cargoHash = "sha256-Fj70uKYzEKxeZeNrqlwM7ZFJ+K1tz10RqLndrdY40CE="; + inherit (nushell) version src; + cargoHash = "sha256-o/cOHlwo2TBlO+e6DBBKf5x6bgVGozVNMGRb2nCWPT4="; + nativeBuildInputs = [ pkg-config ]; buildInputs = [ openssl ] ++ lib.optionals stdenv.isDarwin [ Security ]; cargoBuildFlags = [ "--package nu_plugin_gstat" ]; - doCheck = false; # some tests fail + + checkPhase = '' + cargo test --manifest-path crates/nu_plugin_gstat/Cargo.toml + ''; + + passthru.updateScript = nix-update-script { + # Skip the version check and only check the hash because we inherit version from nushell. + extraArgs = [ "--version=skip" ]; + }; + meta = with lib; { description = "A git status plugin for Nushell"; - homepage = "https://github.com/nushell/nushell/tree/main/crates/nu_plugin_gstat"; + homepage = "https://github.com/nushell/nushell/tree/${version}/crates/nu_plugin_gstat"; license = licenses.mpl20; - maintainers = with maintainers; [ mrkkrp ]; + maintainers = with maintainers; [ mrkkrp aidalgol ]; platforms = with platforms; all; }; } |