[Nix-dev] Remapping Console Key Bindings

Rodney Lorrimar dev at rodney.id.au
Sat Jan 14 07:32:50 CET 2017


Hi Mark,

This is what I do for caps lock as control key:

    # configuration.nix
    i18n.consoleKeyMap = (pkgs.writeText "keys.map" ''
      keymaps 0-255
      keycode 58 = Control
    '');

It works for the US keyboard layout. If you use another layout, you
might want to edit the output of dumpkeys ("kbd" package) yourself, and
load that file as i18n.consoleKeyMap.


Cheers,

Rodney


More information about the nix-dev mailing list