23 November 2008

gconftool to play with settings

gconf-editor is a very good utility where one can change behavior or setting or preference of any application using click. today I discovered its command line version --
using this you can set behavior to preference of any application in command line or in shell script.
for example , just after installation of fedora , i use to open Nautilus (the file browser) and open its preference to set it "always open in browser mode" and 'single click to double click' behavior. Same with gedit and other tool to make setting.
But same thing you can perform with gconftool-2 like this..

gconftool-2 --set "/apps/nautilus/preferences/always_use_browser" --type bool TRUE
gconftool-2 --set "/apps/nautilus/preferences/click_policy" --type string "single"

do not use sudo,, you are making setting for you and not root.

you can bundle up such command to make your own theme which you can install from shell. (actually i got this idea form here - - )

The format is very simple

gconftool-2 --set KEY_NAME --type TYPE VALUE

you need to browse in gconf-editor to know what is key name for a particular setting.

* gconftool-2 -R will list all the setting. So you can save all initial settings. Like
gconftool-2 -R / > save.txt
* Search a given key,
$ gconftool-2 -R / | grep screensaver

more at :
Post a Comment