Don't I recall some sort of user profile directory being
implemented in Win98 even for single user machines? I
thought it offered a login prompt and, if you cancelled
that, you're in as admin or some other such robustly
secure idea. ;p
I'm not as sure about Win98, but on Win95 you could optionally configure
user profiles, which allowed you to choose a user name on login.
I also understood that Windows NT, 2K, and ME have the
concept of user accounts, home directories, and so forth
as can be (and usually is) usually implemented at the
primary domain controller. If that's true, then it's
entirely reasonable to expect such settings be made even
on single-user machines; to plop them all into a global
file will make the admins at any well-run Windows site
insane and cause them to either jump through flaming hoops
to please the users or, more likely, refuse to install or
support the product.
Windows NT based operating systems implement
%HOMEDRIVE and %HOMEPATH - very rarely set to anything
other than C:\, even in domains. For practical purposes,
useless, as C:\ is a hopeless default. (And as the default
isn't user-specific, it's no use for user config files
anyway).
%USERPROFILE - difficult to manage as this is either a
subdirectory of the Windows directory (nasty for security,
backups, etc) or a directory name with spaces in (hard to
manage from the command line). In either case, it is *not*
the right place to put application config files - these can
go in one of a number of *hidden* subdirectories of this,
and hidden directories are almost impossible to work with in
Windows
The registry - the "right" place, in some sense. Not a file-based
interface, so needs non-portable handling. We've all heard
enough complaints about the manageability of the regsitry, so
I won't add more.
There is no standard. Even Microsoft programs use multiple, incompatible,
schemes, often changing even between versions.
Do whatever seems sensible, but don't make the mistake of assuming that
there is a standard. And don't think that users will appreciate you
inventing a new one for them. And trying to implement Unix standards on
Windows boxes will not sort this out - Windows users can be anti-Unix, just
as much as Unix users can be anti-Windows (and even experienced Windows
users with no axe to grind will point out that things *are* different, and
trying to make them the same won't work).
The nearest to a practical standard is to put *all* files related to an
application in one directory. Executables, config files, the lot. It's
multi-user hostile, but that isn't a practical issue in most cases. On
Windows, the unit of multi-user access is the network, not the machine.
Windows machines are usually only used by a single user, in practice.
It's not perfect, but it's pragmatic.
Oh, and by the way - most admins at Windows sites will cheerfully admit that
being insane is a requirement of the job
--j, who doesn't support chaos just because it's the natural state
of the universe.
But adding to the chaos by trying to make an apple look like an orange
doesn't help in any practical way...
Paul, who has seen too much of this mess to retain his sanity
···
From: Jim Meyer [mailto:purp@wildbrain.com]