GNOME Bugzilla – Bug 522811
Evince doesn't match XDG FreeDesktop directories specs
Last modified: 2010-10-10 08:57:24 UTC
Please describe the problem: I found that Evince 2.22 (Ubuntu Hardy alpha 6) places its files in .gnome2/evince/ which doesn't match FreeDesktop directories specs : The default for $XDG_CONFIG_HOME is $HOME/.config, the default for $XDG_DATA_HOME is $HOME/.local/share. So all applications should look for those environment variables and use those default values if the variables are not set. See http://www.freedesktop.org/wiki/Specifications/basedir-spec See also - http://ploum.frimouvy.org/?184-cleaning-user-preferences-keeping-user-data (main post and comment#8) - http://www.aigarius.com/blog/2007/01/10/fhs-extension-for-user-home-folders/ Steps to reproduce: 1. 2. 3. Actual results: Expected results: Does this happen every time? Other information:
*** Bug 532616 has been marked as a duplicate of this bug. ***
Created attachment 120582 [details] [review] Use XDG base dirs Use ~/.gnome2/evince/ if it already exists, otherwise use $XDG_CONFIG_HOME/evince/. If $XDG_CONFIG_HOME/evince/ exists, put accels there, otherwise fall back to the old behavior. I'm not sure if the fact that it puts the accels in ~/.gnome2/accelsevince and not ~/.gnome2/accels/evince is a bug or not - I left that the way it was.
Personally I think ev-metadata.xml belong more into XDG_CACHE_HOME than XDG_CONFIG_HOME ...
You're right. Would the same be true for the accels file? I'm not perfectly clear on exactly what it's used for.
It's used by the in-place menu accelerator editing to store the settings. I guess it can be considered user conf data, for XDG_CONFIG_HOME.
Created attachment 120599 [details] [review] Use XDG base dirs Put ev-metadata.xml in XDG_CACHE_HOME instead.
it would be great if evince could be XDG Base Directory spec compliant for 2.26
seems evince still using ~/.gnome2/evince to store files. evince 2.28
Um, can the patch be committed? What's holding it back?
Comment on attachment 120599 [details] [review] Use XDG base dirs It's totally bitrotten. This code now lives in shell/ev-application.c. I think the ordering of the fallback from .gnome2/evince to XDG_CONFIG_DIR/evince is wrong. It should be the other way; that is default to the XDG conformant one, and only fall back to the old one if XDG one doesn't exist, and the old one does exist.
Fixed in git master