Where keyboard shortcuts settings are stored?

Forum rules
Before you post please read how to get help
Post Reply
dimonomid
Level 1
Level 1
Posts: 18
Joined: Wed Feb 12, 2014 3:33 pm

Where keyboard shortcuts settings are stored?

Post by dimonomid »

Hi all.

I'm exploring and setting up Linux Mint 13 MATE on several machines these days, and I want to set up keyboard shortcuts just once, and then copy configuration files to other machines. But I can't find where these settings are stored.

I have copied all the ~/.* files to temp dir, then made some modifications with keyb shortcuts, then compared directories: current and copied one, and there are no differences (except a couple of strange binary files, they seem not to have needed settings)

So where are these settings?
User avatar
austin.texas
Level 20
Level 20
Posts: 12045
Joined: Tue Nov 17, 2009 3:57 pm
Location: at /home

Re: Where keyboard shortcuts settings are stored?

Post by austin.texas »

When I want to find where .config files are hidden, I make a small change in the config (in this case, keyboard shortcuts), and then immediately run the command
find $HOME -cmin 2

That command will list all the files created or changed in the last 2 minutes, and, of course, you can change the 2 to 5 or 14 or whatever...
Mint 18.2 Cinnamon, Quad core AMD A8-3870 with Radeon HD Graphics 6550D, 8GB DDR3, Ralink RT2561/RT61 802.11g PCI
Linux Linx 2018
dimonomid
Level 1
Level 1
Posts: 18
Joined: Wed Feb 12, 2014 3:33 pm

Re: Where keyboard shortcuts settings are stored?

Post by dimonomid »

austin.texas wrote:When I want to find where .config files are hidden, I make a small change in the config (in this case, keyboard shortcuts), and then immediately run the command
find $HOME -cmin 2

That command will list all the files created or changed in the last 2 minutes, and, of course, you can change the 2 to 5 or 14 or whatever...
But unfortunately there are no files changed in my $HOME when I change keyboard shortcuts settings. Sounds strangely, but true. Any ideas where else could they be stored?
User avatar
austin.texas
Level 20
Level 20
Posts: 12045
Joined: Tue Nov 17, 2009 3:57 pm
Location: at /home

Re: Where keyboard shortcuts settings are stored?

Post by austin.texas »

That is a real mystery. I searched for it with no results.
The only possible clue is that .config/dconf/user was altered. But that is a binary file, not a text file, so I am just guessing.
Mint 18.2 Cinnamon, Quad core AMD A8-3870 with Radeon HD Graphics 6550D, 8GB DDR3, Ralink RT2561/RT61 802.11g PCI
Linux Linx 2018
jeo
Level 1
Level 1
Posts: 1
Joined: Wed Jun 03, 2015 7:14 pm

Re: Where keyboard shortcuts settings are stored?

Post by jeo »

After some research...

dconf dump /org/cinnamon/

Notice that this output only shows the modified/added shortcuts

to import/export check the user of the dconf command (you may need to install it first, apt-get install dconf-cli):

#export
dconf dump /org/cinnamon/ > file.txt
#import
dconf load /org/cinnamon/ < file.txt
Hitmark7
Level 1
Level 1
Posts: 5
Joined: Tue Jan 29, 2013 2:53 am

Re: Where keyboard shortcuts settings are stored?

Post by Hitmark7 »

Hi!

Time has passed, but I would like to share my little trick. I needed to disable my keyboard shortcuts every time I would like to play Doom2, and re-enable them afterwards. I found that the dconf application that you said is like a key-value register management tool, so I created these aliases:

Code: Select all

alias disableKeyboardShortcuts='
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-right "\"\""
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-left "\"\""
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-down "\"\""
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-up "\"\""

	dconf write /org/mate/marco/window-keybindings/move-to-workspace-right "\"\""
	dconf write /org/mate/marco/window-keybindings/move-to-workspace-left "\"\""
	dconf write /org/mate/marco/window-keybindings/move-to-workspace-down "\"\""
	dconf write /org/mate/marco/window-keybindings/move-to-workspace-up "\"\""
'

alias enableKeyboardShortcuts='
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-right "\"<Primary><Alt>Right\""
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-left "\"<Primary><Alt>Left\""
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-down "\"<Primary><Alt>Down\""
	dconf write /org/mate/marco/global-keybindings/switch-to-workspace-up "\"<Primary><Alt>Up\""

	dconf write /org/mate/marco/window-keybindings/move-to-workspace-right "\"<Primary><Shift><Alt>Right\""
	dconf write /org/mate/marco/window-keybindings/move-to-workspace-left "\"<Primary><Shift><Alt>Left\""
	dconf write /org/mate/marco/window-keybindings/move-to-workspace-down "\"<Primary><Shift><Alt>Down\""
	dconf write /org/mate/marco/window-keybindings/move-to-workspace-up "\"<Primary><Shift><Alt>Up\""
'
They work like a charm :) . Just in case, I am using Linux Mint 19.1 MATE.
Post Reply