From 6c54370a7fe780e2f8c3a03b8c411e780f12200a Mon Sep 17 00:00:00 2001 From: Aly Raffauf Date: Sun, 31 Mar 2024 13:21:27 -0400 Subject: [PATCH] home-manager: added easyeffects module with presets --- homeManagerModules/userServices/default.nix | 2 +- .../userServices/easyeffects/default.nix | 23 ++++ .../userServices/easyeffects/framework13.json | 103 ++++++++++++++++++ 3 files changed, 127 insertions(+), 1 deletion(-) create mode 100644 homeManagerModules/userServices/easyeffects/default.nix create mode 100644 homeManagerModules/userServices/easyeffects/framework13.json diff --git a/homeManagerModules/userServices/default.nix b/homeManagerModules/userServices/default.nix index c8cd9f85..9a33e5e2 100644 --- a/homeManagerModules/userServices/default.nix +++ b/homeManagerModules/userServices/default.nix @@ -1,7 +1,7 @@ { config, lib, pkgs, ... }: { - imports = [ ./syncthing ]; + imports = [ ./syncthing ./easyeffects ]; userServices.syncthing.enable = lib.mkDefault true; } diff --git a/homeManagerModules/userServices/easyeffects/default.nix b/homeManagerModules/userServices/easyeffects/default.nix new file mode 100644 index 00000000..f2ec518e --- /dev/null +++ b/homeManagerModules/userServices/easyeffects/default.nix @@ -0,0 +1,23 @@ +{ pkgs, lib, config, ... }: { + + options = { + userServices.easyeffects.enable = + lib.mkEnableOption "EasyEffects user service."; + userServices.easyeffects.preset = lib.mkOption { + description = "Name of preset to start with."; + default = ""; + type = lib.types.str; + }; + }; + + config = lib.mkIf config.userServices.easyeffects.enable { + + xdg.configFile."easyeffects/output/framework13.json".source = + ./framework13.json; + + services.easyeffects = { + enable = true; + preset = config.userServices.easyeffects.preset; + }; + }; +} diff --git a/homeManagerModules/userServices/easyeffects/framework13.json b/homeManagerModules/userServices/easyeffects/framework13.json new file mode 100644 index 00000000..591903c3 --- /dev/null +++ b/homeManagerModules/userServices/easyeffects/framework13.json @@ -0,0 +1,103 @@ +{ + "output": { + "blocklist": [], + "equalizer": { + "balance": 0.0, + "bypass": false, + "input-gain": 0.0, + "left": { + "band0": { + "frequency": 101.0, + "gain": -18.1, + "mode": "RLC (BT)", + "mute": false, + "q": 4.36, + "slope": "x1", + "solo": false, + "type": "Lo-shelf" + }, + "band1": { + "frequency": 451.0, + "gain": -5.48, + "mode": "RLC (BT)", + "mute": false, + "q": 2.46, + "slope": "x1", + "solo": false, + "type": "Bell" + }, + "band2": { + "frequency": 918.0, + "gain": -4.76, + "mode": "RLC (BT)", + "mute": false, + "q": 2.44, + "slope": "x1", + "solo": false, + "type": "Bell" + }, + "band3": { + "frequency": 9700.0, + "gain": 8.1, + "mode": "RLC (BT)", + "mute": false, + "q": 2.0, + "slope": "x1", + "solo": false, + "type": "Bell" + } + }, + "mode": "IIR", + "num-bands": 4, + "output-gain": 0.0, + "pitch-left": 0.0, + "pitch-right": 0.0, + "right": { + "band0": { + "frequency": 101.0, + "gain": -18.1, + "mode": "RLC (BT)", + "mute": false, + "q": 4.36, + "slope": "x1", + "solo": false, + "type": "Lo-shelf" + }, + "band1": { + "frequency": 451.0, + "gain": -5.48, + "mode": "RLC (BT)", + "mute": false, + "q": 2.46, + "slope": "x1", + "solo": false, + "type": "Bell" + }, + "band2": { + "frequency": 918.0, + "gain": -4.76, + "mode": "RLC (BT)", + "mute": false, + "q": 2.44, + "slope": "x1", + "solo": false, + "type": "Bell" + }, + "band3": { + "frequency": 9700.0, + "gain": 8.1, + "mode": "RLC (BT)", + "mute": false, + "q": 2.0, + "slope": "x1", + "solo": false, + "type": "Bell" + } + }, + "split-channels": false + }, + "plugins_order": [ + "equalizer" + ] + } +}