From 6745da6dce1ae023e934e1ea17f7209641fcb9ee Mon Sep 17 00:00:00 2001 From: AndersonTorres Date: Tue, 9 Aug 2022 01:22:46 -0300 Subject: [PATCH] rtorrent: change settings to extraConfig Per NixOS RFC #42, settings should be reserved to structured settings, whereas extraConfig is used for stringly configuration. --- modules/programs/rtorrent.nix | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/modules/programs/rtorrent.nix b/modules/programs/rtorrent.nix index 95015e2c..5cfbe2f1 100644 --- a/modules/programs/rtorrent.nix +++ b/modules/programs/rtorrent.nix @@ -9,10 +9,16 @@ let in { meta.maintainers = [ maintainers.marsam ]; + imports = [ + (mkRenamedOptionModule # \ + [ "programs" "rtorrent" "settings" ] # \ + [ "programs" "rtorrent" "extraConfig" ]) + ]; + options.programs.rtorrent = { enable = mkEnableOption "rTorrent"; - settings = mkOption { + extraConfig = mkOption { type = types.lines; default = ""; description = '' @@ -29,6 +35,6 @@ in { home.packages = [ pkgs.rtorrent ]; xdg.configFile."rtorrent/rtorrent.rc" = - mkIf (cfg.settings != "") { text = cfg.settings; }; + mkIf (cfg.extraConfig != "") { text = cfg.extraConfig; }; }; }