2009-01-25 16:49:08 +01:00
|
|
|
{pkgs, config, ...}:
|
|
|
|
|
|
|
|
let
|
|
|
|
inherit (pkgs.lib) mkOption mkIf;
|
|
|
|
cfg = config.services.xserver.windowManager.wmii;
|
2009-04-12 00:28:38 +02:00
|
|
|
|
|
|
|
option = { services = { xserver = { windowManager = {
|
|
|
|
|
|
|
|
wmii = {
|
|
|
|
enable = mkOption {
|
|
|
|
default = false;
|
|
|
|
example = true;
|
|
|
|
description = "Enable the wmii window manager.";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
}; }; }; };
|
2009-01-25 16:49:08 +01:00
|
|
|
in
|
|
|
|
|
2009-04-12 00:28:38 +02:00
|
|
|
mkIf cfg.enable {
|
|
|
|
require = option;
|
|
|
|
|
2009-01-25 16:49:08 +01:00
|
|
|
services = {
|
|
|
|
xserver = {
|
|
|
|
|
|
|
|
windowManager = {
|
2009-04-12 00:28:38 +02:00
|
|
|
session = [{
|
2009-01-25 16:49:08 +01:00
|
|
|
name = "wmii";
|
|
|
|
start = "
|
|
|
|
${pkgs.wmiiSnap}/bin/wmii &
|
|
|
|
waitPID=$!
|
|
|
|
";
|
|
|
|
}];
|
|
|
|
};
|
|
|
|
|
|
|
|
};
|
|
|
|
};
|
2009-04-12 00:28:38 +02:00
|
|
|
|
|
|
|
environment = {
|
|
|
|
extraPackages = [
|
|
|
|
pkgs.wmiiSnap
|
|
|
|
];
|
|
|
|
};
|
2009-01-25 16:49:08 +01:00
|
|
|
}
|