Как добавить ключ в пустую схему? [закрыто]

Я хотел бы автоматизировать настройку некоторых параметров, в частности добавить некоторые сочетания клавиш в ~ / .config / dconf / пользователь . Вот как это выглядит в редакторе dconf:

org.cinnamon.keybindings org.cinnamon.keybindings.custom-keybindings.custom0

Теперь gsettings (или dconf) может перечислить первый:

$ gsettings get org.cinnamon.keybindings custom-list
['custom0', 'custom1', 'custom2', 'custom3']

Однако я не вижу способа затем добавить новую привязку клавиш или даже прочитать ключи customX .

$ gsettings get org.cinnamon.keybindings.custom-keybinding:/ custom0
No such key 'custom0'

Как добавить, например, ключ custom4 с привязкой = ' g' , command = 'geany' , name = 'Geany' ?

Вывод ответа Донарссону:

$ gsettings get org.cinnamon.keybindings.custom-keybindings:/custom0/ binding
No such schema 'org.cinnamon.keybindings.custom-keybindings'
$ gsettings get org.cinnamon.keybindings.custom-keybinding:/custom0/ binding
''

И снимок экрана после следующей команды. Обратите внимание, что custom4 переходит не к пользовательским привязкам клавиш, а к корню.

gsettings set org.cinnamon.keybindings.custom-keybinding:/custom4/ binding '<Super>g'

gsetting the value

Я использую Linux Mint в качестве операционной системы.

14
задан 6 March 2014 в 01:55

1 ответ

Это - синтаксическая ошибка. Это должно работать:

$ gsettings get org.cinnamon.keybindings.custom-keybinding:/org/cinnamon/keybindings/custom-keybindings/custom0/ binding
<Super>e
$ gsettings get org.cinnamon.keybindings.custom-keybinding:/org/cinnamon/keybindings/custom-keybindings/custom0/ command
nemo
$ gsettings get org.cinnamon.keybindings.custom-keybinding:/org/cinnamon/keybindings/custom-keybindings/custom0/ name
nemo

Для установки новой горячей клавиши:

$ gsettings set org.cinnamon.keybindings.custom-keybinding:/org/cinnamon/keybindings/custom-keybindings/custom4/ binding '<Super>g' &&
gsettings set org.cinnamon.keybindings.custom-keybinding:/org/cinnamon/keybindings/custom-keybindings/custom4/ command 'geany' &&
gsettings set org.cinnamon.keybindings.custom-keybinding:/org/cinnamon/keybindings/custom-keybindings/custom4/ name 'Geany'
0
ответ дан 6 March 2014 в 01:55

Другие вопросы по тегам:

Похожие вопросы: