开发者

What is the gnome keyring api for PyGi?

开发者 https://www.devze.com 2023-03-10 18:55 出处:网络
Does anyone where I can find the gnome keyring api in PyGi? I used to do: import gnomekeyring Now I want to use the new python/gobject introspection so it w开发者_C百科ould be something like:

Does anyone where I can find the gnome keyring api in PyGi?

I used to do:

import gnomekeyring

Now I want to use the new python/gobject introspection so it w开发者_C百科ould be something like:

from gi.repository import GnomeKeyring

But I can't find the module to load. Does someone know if/how I can access the Gnome Keyring api with python gobject introspection?


To access the Secret Service (gnome-keyring) you should use the libsecret (new library replacing libgnome-keyring)

It has builtin support for Gobject Introspection so this should work:

from gi.repository import Secret


PyGI still under development and adaption so it still doesn't have any official documentation or API reference. Every time I need to try something with PyGI I check the C Gnome Development Reference there you can find the C documentation for gnome-keyring. It seems to be very similar to the old gnomekeyring.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号