diff --git a/pkgs/by-name/fx/fx/package.nix b/pkgs/by-name/fx/fx/package.nix index a94c58e97caa..fce5491fa6ac 100644 --- a/pkgs/by-name/fx/fx/package.nix +++ b/pkgs/by-name/fx/fx/package.nix @@ -4,6 +4,8 @@ buildGoModule, fetchFromGitHub, installShellFiles, + versionCheckHook, + writableTmpDirAsHomeHook, }: buildGoModule (finalAttrs: { @@ -30,6 +32,15 @@ buildGoModule (finalAttrs: { --zsh <($out/bin/fx --comp zsh) ''; + nativeInstallCheckInputs = [ + versionCheckHook + writableTmpDirAsHomeHook + ]; + + doInstallCheck = true; + versionCheckProgramArg = "--version"; + versionCheckKeepEnvironment = [ "HOME" ]; + meta = { changelog = "https://github.com/antonmedv/fx/releases/tag/${finalAttrs.src.tag}"; description = "Terminal JSON viewer";