{ config, lib, pkgs, ... }: let cfg = config.my.home.scanner; in { options.my.home.scanner = with lib; { enable = mkEnableOption "scanner configuration"; }; config = lib.mkIf cfg.enable { home.packages = with pkgs; [ tesseract imagemagick exiftool sane-airscan ]; }; }