How do I change dconf keys without a gui (for a post-install script)?
You can use the gsettings
tool.
gsettings set com.canonical.indicator.session show-real-name-on-panel false
The following worked for me on Ubuntu 14.04:
dconf write /org/gnome/gnome-session/auto-save-session true
The value did change and stayed changed after reboot. I had another problem that the windows weren't saved but that's a whole different issue.
dconf dump
+ load
mass export and restore
Dump all settings to a file:
dconf dump / >~/.config/dconf/user.conf
Open that file on a text editor and select the settings that you care about:
editor ~/.config/dconf/user.conf
If you use Vim, you will want this syntax highlight.
If you don't know the name of the setting, but know how to modify it from a GUI like
unity-control-center
, run:dconf watch /
and then modify them. The exact setting will then appear on the terminal.
When you want to restore those settings, run:
dconf load / <~/.config/dconf/user.conf
Git track the config file to never lose it. homeshick is my current favorite method.
Tested on Ubuntu 15.10. Tip adapted from: http://catern.com/2014/12/21/plain-text-configuration-gnome.html