Where can I get a list of SCHEMA / PATH / KEY to use with gsettings?
Solution 1
gsettings list-schemas
gets you all the schema. You can also use gsettings list-recursively
for what you want but this program will list all the values for all the keys for all schemas:
(Lest's call the script gsettings-iterate-all
)
#!/bin/bash
# Gnome 3 can be customised from the command line via the gsettings command
# This script should help you to find what you're looking for by
# listing the ranges for all keys for each schema
for schema in $(gsettings list-schemas | sort)
do
for key in $(gsettings list-keys $schema | sort)
do
value="$(gsettings range $schema $key | tr "\n" " ")"
echo "$schema :: $key :: $value"
done
done
Expanding on your example gsettings-iterate-all | grep com.canonical.Unity2d.Launcher
yields
com.canonical.Unity2d.Launcher :: edge-decayrate :: type i
com.canonical.Unity2d.Launcher :: edge-overcome-pressure :: type i
com.canonical.Unity2d.Launcher :: edge-responsiveness :: type d
com.canonical.Unity2d.Launcher :: edge-reveal-pressure :: type i
com.canonical.Unity2d.Launcher :: edge-stop-velocity :: type i
com.canonical.Unity2d.Launcher :: hide-mode :: type i
com.canonical.Unity2d.Launcher :: only-one-launcher :: type b
com.canonical.Unity2d.Launcher :: reveal-mode :: type i
com.canonical.Unity2d.Launcher :: super-key-enable :: type b
You can reroute the output to a file for easy reading.
And for creative folks out there. Here is a list of possible options to gsettings that might help create other scripts.
Solution 2
It's a bit late, but I just started wrestling with this privacy concern...
It looks like com.canonical.Unity.Lenses remote-content-search 'none'
is the toggle you seek.
Sri
Updated on September 18, 2022Comments
-
Sri over 1 year
After doing some research, I found that I can quickly set configuration options using the
gsettings
command in the terminal, instead of installingdconf-editor
orgconf-editor
or CCSM.But we need the SCHEMA/PATH and KEY to set the value.
Syntax is:gsettings set SCHEMA[:PATH] KEY VALUE
For example to never auto-hide the launcher:
gsettings set com.canonical.Unity2d.Launcher hide-mode 0
And, for windows not to overlap the launcher:
gsettings set com.canonical.Unity2d.Launcher use-strut true
So, where can I get a list of all the SCHEMA / PATH / KEY that can be set with gsettings?
No, please don't suggest the
gsettings list-keys
command, because I don't know the possibly hundreds of schema available. -
Sri almost 12 yearsRinzwind, Thank you for the additional useful information. I realized after I posted the question that a full list was available using the command gsettings list-recursively, but like you say, you have given great additional info for creative folks :)
-
Zta over 11 yearsIf you want the keys' default value, this may be of interest: askubuntu.com/questions/196896/…
-
Aditya about 11 yearsThe question asks about where we can get the list of complete Schema. You are providing the one which relates to privacy. This doesn't really answer the question that is asked.
-
Sergiy Kolodyazhnyy almost 9 yearsVery useful ! +1
-
Volker Siegel over 7 years@Rinzwind As a practical note that may be useful: Do not call call a test script
test
(I edited it out). Startingtest
will work just fine - and perfectly do it's job. But it may be/usr/bin/test
; To make it really fast, it's also a shell builtin. - It's job with no arguments is to return exit code0
and keep quiet. (seeman test
) -
user3757405 over 3 yearsAn enhancement suggestion: change to
for schema in $(gsettings list-schemas | grep "^$1" | sort)
, to allow things likegsettings-iterate-all com.canonical
-
Snackoverflow over 2 yearsFor anyone trying to find and disable/modify a certain keybinding, check out this answer which uses a slightly modified version of the same script. The thing is, if you are looking for a certain value from GSettings, the script above does not print out the values, so you must use
list-recursively
for that.