2020-04-24 23:36:52 +00:00
|
|
|
{ config, pkgs, lib, ... }:
|
|
|
|
|
|
|
|
let
|
|
|
|
cfg = config.programs.usbtop;
|
|
|
|
in {
|
|
|
|
options = {
|
2024-05-15 15:35:15 +00:00
|
|
|
programs.usbtop.enable = lib.mkEnableOption "usbtop and required kernel module, to show estimated USB bandwidth";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
config = lib.mkIf cfg.enable {
|
2020-04-24 23:36:52 +00:00
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
usbtop
|
|
|
|
];
|
|
|
|
|
|
|
|
boot.kernelModules = [
|
|
|
|
"usbmon"
|
|
|
|
];
|
|
|
|
};
|
|
|
|
}
|