This is the mail archive of the cygwin-xfree@cygwin.com mailing list for the Cygwin XFree86 project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Environment variables


I can't believe I missed this point: (Maybe because I'm home sick with
all sorts of horrible symptoms - I shouldn't even be on the Net.)

If anyone here writes batch files that test for the OS, %OS%="" is _NOT_
valid for win9x. At least one major Networking client sets %OS%
automatically on login (Novell).

The most reliable tests I found where a little convoluted, and I don't
have them handy, but the logic was basically:

test for known OS values.
if missing
  test for known win 95/98/ME only files
    if missing
      win3.x or dos
   endif
endif

I actually went on to test for dos vs win3.x but I think that's probably
a little extreme here.

Rob


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]