During installation I just want to run a set of commands and not do all the settings with raspi-config
.
How can I set the keyboard layout just with the command line without any further interaction / UIs?
During installation I just want to run a set of commands and not do all the settings with raspi-config
.
How can I set the keyboard layout just with the command line without any further interaction / UIs?
I figured out this sed
command line to set e.g. german keyboard layout:
sudo sed -i -e 's/XKBLAYOUT="[a-z][a-z]"/XKBLAYOUT="de"/' /etc/default/keyboard
It's possible to do this via raspi-config nonint do_configure_keyboard
. E.g. raspi-config nonint do_configure_keyboard us
sets the US keyboard layout.
Reference: Where can I learn about the raspi-config noint parameters?