1{ config, lib, pkgs, ... }:
2
3let
4 cfg = config.hardware.keyboard.zsa;
5 inherit (lib) mkEnableOption mkIf mdDoc;
6
7in
8{
9 options.hardware.keyboard.zsa = {
10 enable = mkEnableOption (mdDoc ''
11 udev rules for keyboards from ZSA like the ErgoDox EZ, Planck EZ and Moonlander Mark I.
12 You need it when you want to flash a new configuration on the keyboard
13 or use their live training in the browser.
14 You may want to install the wally-cli package.
15 '');
16 };
17
18 config = mkIf cfg.enable {
19 services.udev.packages = [ pkgs.zsa-udev-rules ];
20 };
21}