1{ config, lib, ... }: 2 3let 4 inherit (lib) mkOption mkIf types; 5 cfg = config.programs.screen; 6in 7 8{ 9 ###### interface 10 11 options = { 12 programs.screen = { 13 14 screenrc = mkOption { 15 default = ""; 16 description = '' 17 The contents of /etc/screenrc file. 18 ''; 19 type = types.lines; 20 }; 21 }; 22 }; 23 24 ###### implementation 25 26 config = mkIf (cfg.screenrc != "") { 27 environment.etc."screenrc".text = cfg.screenrc; 28 }; 29 30}