about summary refs log tree commit diff
path: root/nixos/modules
diff options
context:
space:
mode:
authorAndersonTorres <torres.anderson.85@protonmail.com>2020-05-13 01:26:41 -0300
committerAndersonTorres <torres.anderson.85@protonmail.com>2020-05-13 21:32:54 -0300
commit1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e (patch)
tree6f39d320713d31d15a270a6a89ce3cb54c758227 /nixos/modules
parent43ce2a52199100976b18e95c731a2b7879db8091 (diff)
downloadnixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.tar
nixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.tar.gz
nixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.tar.bz2
nixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.tar.lz
nixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.tar.xz
nixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.tar.zst
nixlib-1c2c0b2eb8ead11d06bd840e9a1d6b4d1f86d49e.zip
lwm: init at 1.2.4
lwm is a lightweight window manager
Diffstat (limited to 'nixos/modules')
-rw-r--r--nixos/modules/services/x11/window-managers/default.nix1
-rw-r--r--nixos/modules/services/x11/window-managers/lwm.nix25
2 files changed, 26 insertions, 0 deletions
diff --git a/nixos/modules/services/x11/window-managers/default.nix b/nixos/modules/services/x11/window-managers/default.nix
index c8af8fdc29a4..87702c58727a 100644
--- a/nixos/modules/services/x11/window-managers/default.nix
+++ b/nixos/modules/services/x11/window-managers/default.nix
@@ -22,6 +22,7 @@ in
     ./i3.nix
     ./jwm.nix
     ./leftwm.nix
+    ./lwm.nix
     ./metacity.nix
     ./mwm.nix
     ./openbox.nix
diff --git a/nixos/modules/services/x11/window-managers/lwm.nix b/nixos/modules/services/x11/window-managers/lwm.nix
new file mode 100644
index 000000000000..e2aa062fd13b
--- /dev/null
+++ b/nixos/modules/services/x11/window-managers/lwm.nix
@@ -0,0 +1,25 @@
+{ config, lib, pkgs, ... }:
+
+with lib;
+
+let
+  cfg = config.services.xserver.windowManager.lwm;
+in
+{
+  ###### interface
+  options = {
+    services.xserver.windowManager.lwm.enable = mkEnableOption "lwm";
+  };
+
+  ###### implementation
+  config = mkIf cfg.enable {
+    services.xserver.windowManager.session = singleton {
+      name = "lwm";
+      start = ''
+        ${pkgs.lwm}/bin/lwm &
+        waitPID=$!
+      '';
+    };
+    environment.systemPackages = [ pkgs.lwm ];
+  };
+}