From 597ffada0179d35713f5895859cb7c17af328dcf Mon Sep 17 00:00:00 2001 From: Arpit Chakladar Date: Tue, 15 Sep 2026 05:13:33 +0530 Subject: feat(system/btop): added nvidia and amd graphics driver support --- modules/system/btop/default.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'modules/system/btop/default.nix') diff --git a/modules/system/btop/default.nix b/modules/system/btop/default.nix index 1834aa2..5375a5b 100644 --- a/modules/system/btop/default.nix +++ b/modules/system/btop/default.nix @@ -1,16 +1,22 @@ # Cross-platform graphical process and system monitor { config, + pkgs, lib, ... }: { options.system.btop = { enable = lib.mkEnableOption "Enables btop."; + nvidia.enable = lib.mkEnableOption "Build btop with NVIDIA GPU monitoring support (CUDA)."; + amd.enable = lib.mkEnableOption "Build btop with AMD GPU monitoring support (ROCm)."; package = lib.mkOption { type = lib.types.package; readOnly = true; - default = config.programs.btop.package; + default = pkgs.btop.override { + cudaSupport = config.system.btop.nvidia.enable; + rocmSupport = config.system.btop.amd.enable; + }; description = "The btop package to use."; }; }; @@ -18,6 +24,7 @@ config = lib.mkIf config.system.btop.enable { programs.btop = { enable = true; + package = config.system.btop.package; }; }; } -- cgit v1.2.3