Il giorno gio, 08/12/2011 alle 23.05 +0100, Bernd Schlapsi ha scritto: > Hello, > > how do I correctly define/create an extension which uses gsettings to > store some extension spezific settings? > I found the weather-extension on github > (https://github.com/simon04/gnome-shell-extension-weather) > and created my extension the same way: > https://github.com/brot/gnome-shell-extension-sshsearch > > But with this way I couldn't copy the extension files into > ~/.local/share/gnome-shell/extensions and have > to "install" the extension with configure/make to create the extension > spezific schema+key(s) in the > configuration storage system (GSettings). > > But as far as I understand I couldn't upload my extension to > extensions.gnome.org, because the installed > extensions will be copied to ~/.local/share/gnome-shell/extensions. > > So what's the right way to build an extension which needs the option to > have some user spezific settings > and should be installed with extensions.gnome.org? The short answer: you cannot. The long answer: you cannot in gnome 3.2 (glib 2.30), as GSettings needs schemas that are installed in $XDG_DATA_DIRS, and any other location will cause a crash. You can support gnome 3.4 (starting from 3.3.2 / glib 2.31.4 IIRC), using GSettingsSchemaSource. You can find an example of this at http://git.gnome.org/browse/gnome-shell-extensions/tree/lib/convenience.js Giovanni
Attachment:
signature.asc
Description: This is a digitally signed message part