Location to put user configuration files in windows

前端 未结 3 994
礼貌的吻别
礼貌的吻别 2020-12-15 23:55

I\'m writing a python library that has a per-user configuration file that can be edited by the user of the library. The library also generates logging files. On *nix, the

3条回答
  •  南方客
    南方客 (楼主)
    2020-12-16 00:59

    %APPDATA% is the right place for these (probably in a subdirectory for your library). Unfortunately a fair number of *nix apps ported to Windows don't respect that and I end up with .gem, .ssh, .VirtualBox, etc., folders cluttering up my home directory and not hidden by default as on *nix.

    You can make it easy even for users that don't know much about the layout of the Windows directory structure by having a menu item (or similar) that opens the configuration file in an editor for them.

    If possible, do provide a GUI front-end to the file, though, even if it's quite a simple one. Windows users will expect a Tools | Options menu item that brings up a dialog box allowing them to set options and will be non-plussed by not having one.

提交回复
热议问题