2014-04-14 15:26:48 +01:00
|
|
|
{ config, lib, pkgs, ... }:
|
2013-09-04 12:05:09 +01:00
|
|
|
|
2014-04-14 15:26:48 +01:00
|
|
|
with lib;
|
2009-01-25 15:49:08 +00:00
|
|
|
|
|
|
|
let
|
2009-06-22 21:34:51 +01:00
|
|
|
|
2009-01-25 15:49:08 +00:00
|
|
|
cfg = config.services.xserver.desktopManager.xterm;
|
|
|
|
|
2013-09-04 12:05:09 +01:00
|
|
|
in
|
|
|
|
|
|
|
|
{
|
2009-06-22 21:34:51 +01:00
|
|
|
options = {
|
2009-01-25 15:49:08 +00:00
|
|
|
|
2009-06-22 21:34:51 +01:00
|
|
|
services.xserver.desktopManager.xterm.enable = mkOption {
|
2018-05-13 02:15:23 +01:00
|
|
|
type = types.bool;
|
2019-08-23 16:22:49 +01:00
|
|
|
default = false;
|
2019-06-08 06:01:22 +01:00
|
|
|
defaultText = "config.services.xserver.enable";
|
2009-06-22 21:34:51 +01:00
|
|
|
description = "Enable a xterm terminal as a desktop manager.";
|
2009-01-25 15:49:08 +00:00
|
|
|
};
|
|
|
|
|
2009-06-22 21:34:51 +01:00
|
|
|
};
|
2011-09-14 19:20:50 +01:00
|
|
|
|
2019-05-13 17:57:09 +01:00
|
|
|
config = mkIf cfg.enable {
|
2009-01-25 15:49:08 +00:00
|
|
|
|
2013-09-04 12:05:09 +01:00
|
|
|
services.xserver.desktopManager.session = singleton
|
|
|
|
{ name = "xterm";
|
|
|
|
start = ''
|
|
|
|
${pkgs.xterm}/bin/xterm -ls &
|
|
|
|
waitPID=$!
|
|
|
|
'';
|
2009-01-25 15:49:08 +00:00
|
|
|
};
|
|
|
|
|
2013-09-04 12:05:09 +01:00
|
|
|
environment.systemPackages = [ pkgs.xterm ];
|
2009-01-25 15:49:08 +00:00
|
|
|
|
|
|
|
};
|
2013-09-04 12:05:09 +01:00
|
|
|
|
2009-01-25 15:49:08 +00:00
|
|
|
}
|