delorie.com/archives/browse.cgi   search  
Mail Archives: opendos/1997/10/01/11:17:01

Date: Wed, 01 Oct 1997 16:58:54 +0100
From: Matthias Paul <PAUL-MA AT reze-1 DOT rz DOT rwth-aachen DOT de>
Subject: Re: \ to /
To: opendos AT delorie DOT com
Reply-to: Matthias DOT Paul AT post DOT rwth-aachen DOT de
Message-id: <AB6D206F66@reze-1.rz.rwth-aachen.de>
Organization: Rechenzentrum RWTH Aachen

On Tue, 23 Sep 1997 John L. Spetz wrote:

[SwitChar]
> >> Are there any dos varients which allow the \ to be changed to /
> >> as is usual for unix?
> >
> >DOS itself (int 21h system calls) allows that [neraly] everywhere.
> >So it depends on applications - command.com does not,*sh do etc..
> 
> There was an interrupt call available (37h I think) to change the
> switch character from the default / to, say, - 

Yes, though this so called 'SwitChar API' has been functional in 
MS-DOS/PC-DOS 2.xx, only.  However, it is also functional under OS/2
and with any of the single-user DR DOS 3.4+, PalmDOS, Novell DOS, 
and OpenDOS versions (Ralf Brown's interrupt lists INTER53 still 
states this wrong). You can change the SwitChar, which's default 
is '/', to any other char (but only '-' makes sense).  

Under DR DOS 5.0+, a changed SwitChar is indicated by the COMMAND.COM
PROMPT $p$g by changing the very first '\' in the path to a '/'. 
This can be interpreted as a remainder, that the COMMAND.COM prompt 
now not only accepts '\' in paths, but also '/' (on the API level, 
you can always use '/' or '\' no matter of the current SwitChar 
setting).  And, of course, the option switch is now set to the 
SwitChar.

During the NWDOS update history they implemented improved SwitChar 
support for the utilities, and with the latest Update 15/2 finally 
even COMMAND.COM honored it (except for the help screen).  Since 
fortunately the Novell DOS patches have now been merged with OpenDOS 
7.02, COD now also should come with SwitChar support for almost every 
(important) external utility (not yet verified).  

Note, that the actual SwitChar support depends on the implementation 
of the utilities.  Some are hardwired to accept only '/', some
always use the current SwitChar (there is also an API function to
get this info), some are hardcoded to accept '/' and '-', some
have the option switch optional, and some follow other combinations.  
I vote to all the programmers to modify all your tools to let them
at least accept '/', '- ', and the current SwitChar, including 
updating the help screens.  This is rather easy to be done, though 
there are some situations, where the option parsing routines need to 
take into account, that a '/' sometimes also might be a filenames 
slash, that tools like ATTRIB or MEMMAX also use the '-' as minus, 
and that other SwitChar's than '/' or '-' may actually cause 
misinterpreting the command line.

> use.  There is even a TSR available at Simtel somewhere to restore
> this feature to newer MSDOS versions where MS has withdrawn support
> for the interrupt.  

You can find such on e.g. Ralf Brown's web-page, but under OpenDOS
you don't need to re-implement its function, since its still present.

You just need a small tool to call this API, e.g. like SWITCHAR.COM,
which can be found in MPDOSTIP.ZIP available from my web-pages 
(including examples how to handle different SwitChar's in batchjobs 
(e.g. MEM.BAT), and overviews on actual SwitChar support with the 
various OpenDOS/Novell DOS utilities (NWDOSTIP.TXT) - yes, it 
differs...).

Finally, my OpenDOS IBMBIO.COM ALPHA1+ update (also available from my 

 URL: http://www.rhrz.uni-bonn.de/~uzs180/opendeng.html 

page) re-introduced the old CONFIG.SYS SWITCHAR= directive.


[IBMBIO update]
Please, also watch out for updated web-pages and my IBMBIO.COM 
ALPHA3 (IBMBIOA3.ZIP) being planned for release within the next 
few days (read as 'within this week').  

Compared to ALPHA2, the new update 
- will introduce localized kernels for French, Spanish, and 
  Italian systems (English and German versions have been ever since)
- more improvements in CONFIG.SYS language  
- more flexibility in booting from other drives than A:/C:, 
  and in multi-boot scenarios with other OSes on the same disks
- will run with Novell DOS 7, OpenDOS 7.01, *and* 7.02 
- will have several minor and one major bug (trashing of the 
  ROS equipment word in some scenarions) fixed 
- more detailed documentation 
- more...

Somewhat surprisingly, though my pages have a constant high stream of 
visitors, there has only been a minimal flow back for the ALPHA1 and 
ALPHA2 kernels.  I hope to NOW receive all your *detailed* reports 
and contributions, or aren't there any bugs any more???

 Matthias
 
--------------------------------------------------------------------
 Snail mail: Matthias Paul, Ubierstrasse 28, D-50321 Bruehl, Germany
 New eMail : <Matthias DOT Paul AT post DOT rwth-aachen DOT de>                    
 Web       : URL: http://www.rhrz.uni-bonn.de/~uzs180/mpdokeng.html 
--------------------------------------------------------------------

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019