[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-gnubg] .gnubgautorc under windows

From: Holger
Subject: Re: [Bug-gnubg] .gnubgautorc under windows
Date: Fri, 17 Oct 2003 15:39:33 +0200

At 15:02 17.10.2003, Jon Kinsey wrote:
At 12:33 17/10/2003, Holger wrote:

Imho we should better use %APPDATA% if we decide to not leave the files below the gnubg install tree. At least here on this machine no single application has placed any file or folder directly in %USERPROFILE%.
The paths are:
USERPROFILE=C:\Dokumente und Einstellungen\username
APPDATA=C:\Dokumente und Einstellungen\username\Anwendungsdaten
Mozilla stores the user profiles e.g. in (thus in %APPDATA%\Mozilla):
C:\Dokumente und Einstellungen\username\Anwendungsdaten\Mozilla\Profiles\default\lt7r8rzs.slt\

I agree, although windows 2000 doesn't have APPDATA defined.

I'm just now sitting at Win2k (Pro), and here it's defined. Don't know what this depends on.

So perhaps several layers are needed:
if APPDATA defined then %APPDATA%
else if USERPROFILE defined %USERPROFILE%\_("Application Data")
else .gnubg

My other idea about saving per user settings in gnubg_folder\.gnubg\username might still be worthwhile to think about. I'm not supporting it too strongly, though.

Extended and thought a bit further it could give this:
On quite a lot of Windows systems the environment variable %USERNAME% exists. Based on this we could store and load user settings from gnubg_folder\.gnubg\username. With this path we would be on the safe side for all Windows versions, whether a %USERPROFILE% or even %APPDATA% folder exists or not. In case %USERNAME% is missing, it could still be set by a switch (e.g. -u) or by getting the current user via GetUserName which exists for all flavours of Windows (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/sysinfo/base/getusername.asp). With the switch one could also create various links and thus mutiple profiles/settings of gnubg for the same user.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]