nixpkgs/nixos/modules/services/x11/urxvtd.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

44 lines
1.0 KiB
Nix
Raw Normal View History

{ config, lib, pkgs, ... }:
# maintainer: siddharthist
with lib;
let
cfg = config.services.urxvtd;
in {
2019-01-07 12:35:20 +00:00
options.services.urxvtd = {
enable = mkOption {
type = types.bool;
default = false;
description = ''
2019-01-07 12:35:20 +00:00
Enable urxvtd, the urxvt terminal daemon. To use urxvtd, run
"urxvtc".
'';
};
package = mkPackageOption pkgs "rxvt-unicode" { };
};
config = mkIf cfg.enable {
systemd.user.services.urxvtd = {
description = "urxvt terminal daemon";
wantedBy = [ "graphical-session.target" ];
partOf = [ "graphical-session.target" ];
path = [ pkgs.xsel ];
serviceConfig = {
2019-01-07 12:35:20 +00:00
ExecStart = "${cfg.package}/bin/urxvtd -o";
Environment = "RXVT_SOCKET=%t/urxvtd-socket";
Restart = "on-failure";
RestartSec = "5s";
};
};
2019-01-07 12:35:20 +00:00
environment.systemPackages = [ cfg.package ];
environment.variables.RXVT_SOCKET = "/run/user/$(id -u)/urxvtd-socket";
};
2019-12-04 16:07:45 +00:00
meta.maintainers = with lib.maintainers; [ rnhmjoj ];
}