diff options
Diffstat (limited to 'desktop.nix')
-rw-r--r-- | desktop.nix | 31 |
1 files changed, 22 insertions, 9 deletions
diff --git a/desktop.nix b/desktop.nix index 2f293d4..a170eaf 100644 --- a/desktop.nix +++ b/desktop.nix @@ -63,17 +63,30 @@ # Enable CUPS to print documents. printing.enable = true; - postgresql = { - enable = false; - initialScript = pkgs.writeText "backend-initScript" '' - CREATE ROLE julian WITH LOGIN PASSWORD 'hejmeddig' CREATEDB; - CREATE DATABASE julian; - GRANT ALL PRIVILEGES ON DATABASE julian TO julian; - ''; - }; - blueman.enable = true; + interception-tools = + let mappings = [ + { from = "KEY_CAPSLOCK"; to = "KEY_LEFTCTRL"; } + { from = "KEY_LEFTALT"; to = "KEY_LEFTMETA"; } + { from = "KEY_102ND"; to = "KEY_LEFTALT"; } + ]; + mapper = pkgs.callPackage ./intcp-mapper.nix { inherit mappings; }; + intercept = pkgs.interception-tools; + in { + enable = true; + # We will just use our own here + plugins = []; + + udevmonConfig = '' + - JOB: "${intercept}/bin/intercept -g $DEVNODE | ${mapper}/bin/mapper | ${intercept}/bin/uinput -d $DEVNODE" + DEVICE: + EVENTS: + EV_KEY: ${builtins.toJSON (map (m: m.from) mappings) } + ''; + }; + + udev.packages = [ pkgs.yubikey-personalization ]; }; |