fork/home-manager
git clone https://git.julia.blue/fork/home-manager
75790441
master
1{ config , lib , pkgs , ...} : 2 3with lib ; 4 5let 6 7cfg = config . services . xembed-sni-proxy ; 8 9in { 10meta . maintainers = [ maintainers . rycee ]; 11 12options = { 13services . xembed-sni-proxy = { 14enable = mkEnableOption "XEmbed SNI Proxy" ; 15 16package = mkOption { 17type = types . package ; 18default = pkgs . plasma-workspace ; 19defaultText = literalExpression "pkgs.plasma-workspace" ; 20description = '' 21Package containing the {command}`xembedsniproxy` 22program. 23'' ; 24}; 25}; 26}; 27 28config = mkIf cfg . enable { 29assertions = [ 30( lib . hm . assertions . assertPlatform "services.xembed-sni-proxy" pkgs 31lib . platforms . linux ) 32]; 33 34systemd . user . services . xembed-sni-proxy = { 35Unit = { 36Description = "XEmbed SNI Proxy" ; 37After = [ "graphical-session-pre.target" ]; 38PartOf = [ "graphical-session.target" ]; 39}; 40 41Install = { WantedBy = [ "graphical-session.target" ]; }; 42 43Service = { 44Environment = "PATH= ${ config . home . profileDirectory } /bin" ; 45ExecStart = " ${ cfg . package } /bin/xembedsniproxy" ; 46Restart = "on-abort" ; 47}; 48}; 49}; 50}