From 8def3835111f0b16850736aa210ca542fcd02af6 Mon Sep 17 00:00:00 2001 From: Robert Helgesson Date: Mon, 16 Sep 2019 21:43:53 +0200 Subject: [PATCH] mpd: allow path literal values in options This allows specifying, for example, the music directory using path literals without causing the directory to be copied to the Nix store. Suggested-by: Silvan Mosberger (cherry picked from commit b0544c8cded820fc1439c26b4fc7485846430516) --- modules/services/mpd.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/services/mpd.nix b/modules/services/mpd.nix index fbcf9e94..673d6510 100644 --- a/modules/services/mpd.nix +++ b/modules/services/mpd.nix @@ -46,6 +46,7 @@ in { type = types.path; default = "${config.home.homeDirectory}/music"; defaultText = "$HOME/music"; + apply = toString; # Prevent copies to Nix store. description = '' The directory where mpd reads music from. ''; @@ -55,6 +56,7 @@ in { type = types.path; default = "${cfg.dataDir}/playlists"; defaultText = ''''${dataDir}/playlists''; + apply = toString; # Prevent copies to Nix store. description = '' The directory where mpd stores playlists. ''; @@ -79,6 +81,7 @@ in { type = types.path; default = "${config.xdg.dataHome}/${name}"; defaultText = "$XDG_DATA_HOME/mpd"; + apply = toString; # Prevent copies to Nix store. description = '' The directory where MPD stores its state, tag cache, playlists etc.