Keyboard layouts


#1

Hello,
I’d like to configure an Italian keyboard: could someone give me detailed instruction? Thanks


#2

Set

services.xserver.layout = "it"

in your configuration.nix to set the Italian keyboard layout. There is also a Wiki page with additional information.


#3

but where in configuration.nix should I put that line? Between braces? I tried several places in that script but to no avail. TIA


#4

The basic format of configuration.nix is:

{ ... }:

{
  # Your configuration goes here, for example...
  services.xserver.layout = "it";
  i18n.consoleUseXkbConfig = true;

  # This value determines the NixOS release with which your system is to be
  # compatible, in order to avoid breaking some software such as database
  # servers. You should change this only after NixOS release notes say you
  # should.
  system.stateVersion = "18.09"; # Did you read the comment?
}

Anywhere inside that second set of brackets should work fine.

Make sure you run nixos-rebuild switch after modifying the file for the changes to take effect.