diff options
author | Hurshal Patel <hurshal@imap.cc> | 2016-04-19 23:24:53 -0700 |
---|---|---|
committer | Hurshal Patel <hurshal@imap.cc> | 2016-06-07 23:58:06 -0700 |
commit | 3913aaeaadc75d6beeb632abefc1e39608968fec (patch) | |
tree | 0db46e166b380e8d4a68b280464e35cf5adfa657 /nixos/modules | |
parent | 55028d556ffe1b08b6ced55b514f8506188fdb6d (diff) |
xbanish service: init at 1.4
Diffstat (limited to 'nixos/modules')
-rw-r--r-- | nixos/modules/module-list.nix | 1 | ||||
-rw-r--r-- | nixos/modules/services/x11/xbanish.nix | 30 |
2 files changed, 31 insertions, 0 deletions
diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index 509634cf34c1d..f30433bed3af2 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -490,6 +490,7 @@ ./services/x11/window-managers/windowlab.nix ./services/x11/window-managers/wmii.nix ./services/x11/window-managers/xmonad.nix + ./services/x11/xbanish.nix ./services/x11/xfs.nix ./services/x11/xserver.nix ./system/activation/activation-script.nix diff --git a/nixos/modules/services/x11/xbanish.nix b/nixos/modules/services/x11/xbanish.nix new file mode 100644 index 0000000000000..e1e3cbc8e4412 --- /dev/null +++ b/nixos/modules/services/x11/xbanish.nix @@ -0,0 +1,30 @@ +{ config, lib, pkgs, ... }: + +with lib; + +let cfg = config.services.xbanish; + +in { + options.services.xbanish = { + + enable = mkEnableOption "xbanish"; + + arguments = mkOption { + description = "Arguments to pass to xbanish command"; + default = ""; + example = "-d -i shift"; + type = types.str; + }; + }; + + config = mkIf cfg.enable { + systemd.user.services.xbanish = { + description = "xbanish hides the mouse pointer"; + wantedBy = [ "default.target" ]; + serviceConfig.ExecStart = '' + ${pkgs.xbanish}/bin/xbanish ${cfg.arguments} + ''; + serviceConfig.Restart = "always"; + }; + }; +} |