2022-12-17 10:02:37 +00:00
|
|
|
{ config, lib, pkgs, ... }:
|
|
|
|
|
|
|
|
let
|
2024-04-21 15:54:59 +00:00
|
|
|
inherit (lib) mkEnableOption mkIf mkPackageOption singleton;
|
2022-12-17 10:02:37 +00:00
|
|
|
cfg = config.services.xserver.windowManager.katriawm;
|
|
|
|
in
|
|
|
|
{
|
|
|
|
###### interface
|
|
|
|
options = {
|
|
|
|
services.xserver.windowManager.katriawm = {
|
2024-04-21 15:54:59 +00:00
|
|
|
enable = mkEnableOption "katriawm";
|
2024-01-02 11:29:13 +00:00
|
|
|
package = mkPackageOption pkgs "katriawm" {};
|
2022-12-17 10:02:37 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
###### implementation
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
services.xserver.windowManager.session = singleton {
|
|
|
|
name = "katriawm";
|
|
|
|
start = ''
|
|
|
|
${cfg.package}/bin/katriawm &
|
|
|
|
waitPID=$!
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
environment.systemPackages = [ cfg.package ];
|
|
|
|
};
|
|
|
|
}
|