8ac5e011d6
GitOrigin-RevId: 2c3273caa153ee8eb5786bc8141b85b859e7efd7
30 lines
663 B
Nix
30 lines
663 B
Nix
{ config, lib, pkgs, ... }:
|
|
|
|
with lib;
|
|
|
|
let
|
|
cfg = config.hardware.digitalbitbox;
|
|
in
|
|
|
|
{
|
|
options.hardware.digitalbitbox = {
|
|
enable = mkOption {
|
|
type = types.bool;
|
|
default = false;
|
|
description = ''
|
|
Enables udev rules for Digital Bitbox devices.
|
|
'';
|
|
};
|
|
|
|
package = mkOption {
|
|
type = types.package;
|
|
default = pkgs.digitalbitbox;
|
|
defaultText = "pkgs.digitalbitbox";
|
|
description = "The Digital Bitbox package to use. This can be used to install a package with udev rules that differ from the defaults.";
|
|
};
|
|
};
|
|
|
|
config = mkIf cfg.enable {
|
|
services.udev.packages = [ cfg.package ];
|
|
};
|
|
}
|