2014-04-14 16:26:48 +02:00
|
|
|
{ config, lib, pkgs, ... }:
|
2013-09-04 13:05:09 +02:00
|
|
|
|
2014-04-14 16:26:48 +02:00
|
|
|
with lib;
|
2009-01-25 16:49:08 +01:00
|
|
|
|
|
|
|
let
|
2009-06-22 22:34:51 +02:00
|
|
|
|
2009-01-25 16:49:08 +01:00
|
|
|
cfg = config.services.xserver.desktopManager.xterm;
|
|
|
|
|
2013-09-04 13:05:09 +02:00
|
|
|
in
|
|
|
|
|
|
|
|
{
|
2009-06-22 22:34:51 +02:00
|
|
|
options = {
|
2009-01-25 16:49:08 +01:00
|
|
|
|
2009-06-22 22:34:51 +02:00
|
|
|
services.xserver.desktopManager.xterm.enable = mkOption {
|
|
|
|
default = true;
|
|
|
|
example = false;
|
|
|
|
description = "Enable a xterm terminal as a desktop manager.";
|
2009-01-25 16:49:08 +01:00
|
|
|
};
|
|
|
|
|
2009-06-22 22:34:51 +02:00
|
|
|
};
|
2011-09-14 20:20:50 +02:00
|
|
|
|
2014-04-03 20:44:31 +02:00
|
|
|
config = mkIf (config.services.xserver.enable && cfg.enable) {
|
2009-01-25 16:49:08 +01:00
|
|
|
|
2013-09-04 13:05:09 +02:00
|
|
|
services.xserver.desktopManager.session = singleton
|
|
|
|
{ name = "xterm";
|
|
|
|
start = ''
|
|
|
|
${pkgs.xterm}/bin/xterm -ls &
|
|
|
|
waitPID=$!
|
|
|
|
'';
|
2009-01-25 16:49:08 +01:00
|
|
|
};
|
|
|
|
|
2013-09-04 13:05:09 +02:00
|
|
|
environment.systemPackages = [ pkgs.xterm ];
|
2009-01-25 16:49:08 +01:00
|
|
|
|
|
|
|
};
|
2013-09-04 13:05:09 +02:00
|
|
|
|
2009-01-25 16:49:08 +01:00
|
|
|
}
|