From f4e00ffb2c0180df6d69af7025966acc44a38b7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Leonardo=20Eug=C3=AAnio?= Date: Wed, 18 Jan 2023 01:13:47 -0300 Subject: [PATCH] Extract mpd module --- user/home.nix | 20 +------------------- user/mpd.nix | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+), 19 deletions(-) create mode 100644 user/mpd.nix diff --git a/user/home.nix b/user/home.nix index a2076f9..576da61 100644 --- a/user/home.nix +++ b/user/home.nix @@ -27,6 +27,7 @@ in { ./pass.nix ./zathura.nix ./man.nix + ./mpd.nix inputs.hyprland.homeManagerModules.default ] ++ lib.optional (desktop == "sway") ./sway.nix; @@ -181,25 +182,6 @@ in { enable = true; indicator = true; }; - services.mpd = { - enable = true; - musicDirectory = config.home.homeDirectory + "/Música"; - extraConfig = '' - restore_paused "yes" - auto_update "yes" - audio_output { - type "pulse" - name "My Pulse Output" - mixer_type "hardware" - } - filesystem_charset "UTF-8" - ''; - }; - services.mpdris2 = { - enable = true; - multimediaKeys = true; - notifications = true; - }; # This value determines the Home Manager release that your # configuration is compatible with. This helps avoid breakage diff --git a/user/mpd.nix b/user/mpd.nix new file mode 100644 index 0000000..2857919 --- /dev/null +++ b/user/mpd.nix @@ -0,0 +1,21 @@ +{pkgs, config, ...}: { + services.mpd = { + enable = true; + musicDirectory = config.home.homeDirectory + "/Música"; + extraConfig = '' + restore_paused "yes" + auto_update "yes" + audio_output { + type "pulse" + name "My Pulse Output" + mixer_type "hardware" + } + filesystem_charset "UTF-8" + ''; + }; + services.mpdris2 = { + enable = true; + multimediaKeys = true; + notifications = true; + }; +}