23 lines
705 B
Nix
23 lines
705 B
Nix
{ config, pkgs, ... }:
|
|
|
|
{
|
|
environment.etc = {
|
|
"interception/dual-function-keys/capslock.yaml".text = ''
|
|
MAPPINGS:
|
|
- KEY: KEY_CAPSLOCK
|
|
TAP: KEY_ESC
|
|
HOLD: KEY_LEFTCTRL
|
|
'';
|
|
};
|
|
|
|
services.interception-tools = {
|
|
enable = true;
|
|
plugins = [ pkgs.interception-tools-plugins.dual-function-keys ];
|
|
udevmonConfig = ''
|
|
- JOB: "${pkgs.interception-tools}/bin/intercept -g $DEVNODE | ${pkgs.interception-tools-plugins.dual-function-keys}/bin/dual-function-keys -c /etc/interception/dual-function-keys/capslock.yaml | ${pkgs.interception-tools}/bin/uinput -d $DEVNODE"
|
|
DEVICE:
|
|
EVENTS:
|
|
EV_KEY: [ KEY_CAPSLOCK ]
|
|
'';
|
|
};
|
|
}
|