From be5ad1d07c21e9e2bab697098a35859a51f20650 Mon Sep 17 00:00:00 2001 From: James Felix Black Date: Tue, 14 Jul 2015 12:35:35 -0400 Subject: [PATCH] window-manager service: add notion Add the notion window manager to the windowManager service definition. --- .../services/x11/window-managers/default.nix | 1 + .../services/x11/window-managers/notion.nix | 32 +++++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 nixos/modules/services/x11/window-managers/notion.nix diff --git a/nixos/modules/services/x11/window-managers/default.nix b/nixos/modules/services/x11/window-managers/default.nix index 097e4fe70d58..a8b1044ad365 100644 --- a/nixos/modules/services/x11/window-managers/default.nix +++ b/nixos/modules/services/x11/window-managers/default.nix @@ -16,6 +16,7 @@ in ./i3.nix ./metacity.nix ./openbox.nix + ./notion.nix ./ratpoison.nix ./sawfish.nix ./stumpwm.nix diff --git a/nixos/modules/services/x11/window-managers/notion.nix b/nixos/modules/services/x11/window-managers/notion.nix new file mode 100644 index 000000000000..1bfc2a86e965 --- /dev/null +++ b/nixos/modules/services/x11/window-managers/notion.nix @@ -0,0 +1,32 @@ +{ config, lib, pkgs, ... }: + +with lib; + +let + cfg = config.services.xserver.windowManager.notion; +in + +{ + options = { + services.xserver.windowManager.notion = { + enable = mkOption { + default = false; + example = true; + description = "Enable the notion tiling window manager."; + }; + }; + }; + + config = mkIf cfg.enable { + services.xserver.windowManager = { + session = [{ + name = "notion"; + start = '' + ${pkgs.notion}/bin/notion & + waitPID=$! + ''; + }]; + }; + environment.systemPackages = [ pkgs.notion ]; + }; +}