Add xserver integration of i3 WM.

This allows to set i3 as the default window manager in the system configuration.
This commit is contained in:
aszlig 2012-06-04 21:19:12 +02:00
parent f2a33809c1
commit b78ce79f89
2 changed files with 31 additions and 0 deletions

View File

@ -14,6 +14,7 @@ in
./twm.nix
./wmii.nix
./xmonad.nix
./i3.nix
];
options = {

View File

@ -0,0 +1,30 @@
{pkgs, config, ...}:
let
inherit (pkgs.lib) mkOption mkIf;
cfg = config.services.xserver.windowManager.i3;
in
{
options = {
services.xserver.windowManager.i3 = {
enable = mkOption {
default = false;
example = true;
description = "Enable the i3 tiling window manager.";
};
};
};
config = {
services.xserver.windowManager = {
session = mkIf cfg.enable [{
name = "i3";
start = "
${pkgs.i3}/bin/i3 &
waitPID=$!
";
}];
};
};
}