{ config, lib, pkgs, osConfig, ... }: let cfg = config.sydnix.easyeffects; in { options.sydnix.easyeffects = { enable = lib.mkEnableOption "Easyeffects"; }; config = lib.mkIf cfg.enable { services.easyeffects = { enable = true; extraPresets.thanks-ash = builtins.fromJSON (builtins.readFile ./easyeffects/thanks-ash.json); }; warnings = lib.optional (!osConfig.programs.dconf.enable) '' Easyeffects requires services.dconf.enable = true in the NixOS config. ''; }; }