Setting keyboard layouts programmatically
by PaulExordium from LinuxQuestions.org on (#5BN4S)
I have the following bash script in Debian 9/Gnome:
Code:#!/bin/bash
gsettings set org.gnome.desktop.input-sources sources "[('"xkb"','"us"'),('"xkb"','"fr"'),('"xkb"','"it"')]"
gsettings set org.gnome.desktop.input-sources current 1
exit1) The layouts are added as expected, but the selection for the current one has no effect. What am I missing?
2) Where can I find the abbreviations for the variants of a given language?


Code:#!/bin/bash
gsettings set org.gnome.desktop.input-sources sources "[('"xkb"','"us"'),('"xkb"','"fr"'),('"xkb"','"it"')]"
gsettings set org.gnome.desktop.input-sources current 1
exit1) The layouts are added as expected, but the selection for the current one has no effect. What am I missing?
2) Where can I find the abbreviations for the variants of a given language?