From 29027559f042b10fdbfc23e5430a1880787c6b45 Mon Sep 17 00:00:00 2001 From: Jonathan Davies Date: Wed, 14 Jan 2026 22:02:41 +0000 Subject: [PATCH 1/3] rqbit: Add versionCheckHook --- pkgs/by-name/rq/rqbit/package.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pkgs/by-name/rq/rqbit/package.nix b/pkgs/by-name/rq/rqbit/package.nix index edac8459099c..ff5c516cbbb4 100644 --- a/pkgs/by-name/rq/rqbit/package.nix +++ b/pkgs/by-name/rq/rqbit/package.nix @@ -9,6 +9,7 @@ nodejs, nix-update-script, nixosTests, + versionCheckHook, }: let pname = "rqbit"; @@ -63,6 +64,11 @@ rustPlatform.buildRustPackage { doCheck = false; + nativeInstallCheckInputs = [ + versionCheckHook + ]; + doInstallCheck = true; + passthru = { webui = rqbit-webui; updateScript = nix-update-script { From 2292974d37f19035009198c61b1fad3abe3d4f51 Mon Sep 17 00:00:00 2001 From: Jonathan Davies Date: Fri, 13 Feb 2026 22:17:04 +0000 Subject: [PATCH 2/3] rqbit: Remove doCheck to enable checkPhase --- pkgs/by-name/rq/rqbit/package.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/pkgs/by-name/rq/rqbit/package.nix b/pkgs/by-name/rq/rqbit/package.nix index ff5c516cbbb4..dfc9286e646b 100644 --- a/pkgs/by-name/rq/rqbit/package.nix +++ b/pkgs/by-name/rq/rqbit/package.nix @@ -62,8 +62,6 @@ rustPlatform.buildRustPackage { rm crates/librqbit/build.rs ''; - doCheck = false; - nativeInstallCheckInputs = [ versionCheckHook ]; From a6a6c79ccbc904fa10020b69172237ee1bc932e4 Mon Sep 17 00:00:00 2001 From: Jonathan Davies Date: Mon, 2 Mar 2026 12:36:28 +0000 Subject: [PATCH 3/3] rqbit: Install shell completions --- pkgs/by-name/rq/rqbit/package.nix | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/pkgs/by-name/rq/rqbit/package.nix b/pkgs/by-name/rq/rqbit/package.nix index dfc9286e646b..12f3bd54af0c 100644 --- a/pkgs/by-name/rq/rqbit/package.nix +++ b/pkgs/by-name/rq/rqbit/package.nix @@ -3,6 +3,7 @@ stdenv, rustPlatform, fetchFromGitHub, + installShellFiles, pkg-config, openssl, buildNpmPackage, @@ -47,7 +48,10 @@ rustPlatform.buildRustPackage { cargoHash = "sha256-gYasOjrG0oeT/6Ben57MKAvBtgpoSmZ93RZQqSXAxIc="; - nativeBuildInputs = lib.optionals stdenv.hostPlatform.isLinux [ pkg-config ]; + nativeBuildInputs = [ + installShellFiles + ] + ++ lib.optionals stdenv.hostPlatform.isLinux [ pkg-config ]; buildInputs = lib.optionals stdenv.hostPlatform.isLinux [ openssl ]; @@ -62,6 +66,12 @@ rustPlatform.buildRustPackage { rm crates/librqbit/build.rs ''; + postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) '' + for shell in bash fish zsh; do + installShellCompletion --cmd rqbit --$shell <($out/bin/rqbit completions $shell) + done + ''; + nativeInstallCheckInputs = [ versionCheckHook ];