← Back to team overview

zim-wiki team mailing list archive

Re: Win32: configuration path


On Mon, Oct 29, 2012 at 9:52 AM, klo uo <klonuo@xxxxxxxxx> wrote:
> Now I have a suggestion: If you are willing to change this behavior
> for Windows users and their special folders
> (http://en.wikipedia.org/wiki/Special_folder), please don't use just
> %USERPROFILE% aka "os.path.expanduser('~')", as that's *nix setting.
> Appropriate folder for storing application related data is set in env
> variable %APPDATA%. Location for local application data which could
> pair XDG_DATA_HOME, is not set in env variable in Windows XP, but it
> is in Windows 7. Maybe you can just set XDG_DATA_HOME to
> "%APPDATA%\zim" or use some instrument to reveal it for both XP/7/...

This sounds like a reasonable proposal. Indeed setting XDG_DATA to the
relevant path will change the lookup path for zim. Probably you'll
also want to do something similar for XDG_CONFIG and XDG_CACHE.

All these parameters are initialized in zim/config.py, feel free to
patch it accordingly and submit the patch through a bug report.



P.S. behavior is documented in the manual, so you could have saved a
bit of trouble by looking there instead of going over the code ;)

Follow ups