diff --git a/pkgs/by-name/sy/systemctl-tui/package.nix b/pkgs/by-name/sy/systemctl-tui/package.nix index c220fcc8547a..bef931fc92f4 100644 --- a/pkgs/by-name/sy/systemctl-tui/package.nix +++ b/pkgs/by-name/sy/systemctl-tui/package.nix @@ -1,30 +1,32 @@ { lib, rustPlatform, - fetchCrate, - stdenv, - darwin, + fetchFromGitHub, + versionCheckHook, nix-update-script, - testers, - systemctl-tui, }: rustPlatform.buildRustPackage rec { pname = "systemctl-tui"; - version = "0.3.8"; + version = "0.3.9"; - src = fetchCrate { - inherit pname version; - hash = "sha256-i2PKSvjsrITLp3a3EgfFF3IR464mkkDnh8ITLO+o0hU="; + src = fetchFromGitHub { + owner = "rgwood"; + repo = "systemctl-tui"; + tag = "v${version}"; + hash = "sha256-LuE0+HxTWROFbqEqqM6464U236/7qxed7xMUkSNUK68="; }; - cargoHash = "sha256-6cFK1wMO5VICfi3tN140XH9inQOkkSfHVogKhTHtQb8="; + cargoHash = "sha256-R1JV5Hp10I9DO6I2k8sQC2IXJ+U7iJ2iAzb391e895c="; - buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ darwin.apple_sdk.frameworks.AppKit ]; + nativeInstallCheckInputs = [ + versionCheckHook + ]; + versionCheckProgramArg = [ "--version" ]; + doInstallCheck = true; passthru = { updateScript = nix-update-script; - tests.version = testers.testVersion { package = systemctl-tui; }; }; meta = {