Cross-platform configuration, options, settings, preferences, defaults
Posted
by
hippietrail
on Stack Overflow
See other posts from Stack Overflow
or by hippietrail
Published on 2010-12-20T09:24:33Z
Indexed on
2010/12/27
8:53 UTC
Read the original article
Hit count: 273
I'm interested in peoples' views on how best to store preferences and default settings in cross-platform applications.
I primarily work in Perl on *nix and Windows but I'm also interested in the bigger picture.
In the *nix world "dotfiles" (and directories) are very common with system-wide or application default settings generally residing in one path and user-specific settings in the home directory. Such files and dirs begin with a dot "." and are hidden by default from directory listings.
Windows has the registry which also has paths for defaults and per-user overrides.
Certain cross-platforms do it their own way, Firefox uses JavaScript preference files.
Should a cross-platform app use one system across platforms or say dotfiles on *nix and registry on Windows? Does your favourite programming language have a library or module for accessing them in a standard way? Is there an emerging best practice or does everybody roll their own?
© Stack Overflow or respective owner