Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

GNOME: Where does Nautilus store emblem data and how?

Nautilus allows users to set emblems on directories and files but surprisingly it doesn't use the actual file metadata stores like xattr to store this added metadata.

So where and how does Nautilus store this data? (I'd like to access it from outside Nautilus.)

As it seems, GVFS stores such metadata in it's "metadata::emblems" namespace (try the CLI command gvfs-info), but

where does GVFS store it's data? In a separate db, in xattr or in both, depending on namespace??

like image 557
isync Avatar asked Jun 03 '12 23:06

isync


Video Answer


1 Answers

The metadata is stored by GVFS in ~/.local/share/gvfs-metadata/ (strictly speaking in $XDG_DATA_HOME/gvfs-metadata, whereas XDG_DATA_HOME by default is ~/.local/share).

For instance, if you have a partition with label home, then metadata will be stored in ~/.local/share/gvfs-metadata/home.

You can use the GIO API to have access to those attributes in your own program.

like image 174
gpoo Avatar answered Sep 22 '22 13:09

gpoo