Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!asuvax!ncar!zaphod.mps.ohio-state.edu!samsung!emory!gatech!udel!rochester!pt.cs.cmu.edu!o.gp.cs.cmu.edu!MAPS.CS.CMU.EDU!wah From: wah@MAPS.CS.CMU.EDU (Wilson Harvey) Newsgroups: comp.os.msdos.misc Subject: Re: Swapping logical device names under DOS? Keywords: logical device names Message-ID: <1991Feb1.011533.5635@cs.cmu.edu> Date: 1 Feb 91 01:15:33 GMT References: <1991Jan30.201844.13348@cs.cmu.edu> Sender: netnews@cs.cmu.edu (USENET News Group Software) Reply-To: wah@MAPS.CS.CMU.EDU (Wilson Harvey) Organization: Carnegie Mellon University Lines: 40 There seems to be at least two ways of doing this. Thanks to Ralf Brown for the first suggestion, which is to use the ASSIGN command. I can create a batch file with the single line 'assign a=b b=a' in it, and this will swap the logical device names (temporarily, of course). I can undo this by issuing another 'assign' (no arguments). Thanks also to Brad Hines and Lea Fester for suggesting another method that makes use of the SUBST command. It is an open question as to whether this allows one to *swap* the names of the drives. It will, however, allow one to use INSTALL scripts that assume that you are installing from the A: drive. The following sequence of commands illustrates: # Assume that your hard drive is C: and your floppy is B: mkdir c:\scratch cd c:\scratch copy b:\*.* subst a: c:\scratch a: install (I embellished an example from Brad Hines, so I bear any responsibility for inaccuracies.) I cannot comment on the relative merits of either method. I used the first method, as it seemed easiest; it worked just fine for my problem. Others lamented my "upgrade" from DOS3.2 to 4.?; I appreciate your sympathies. Again, many thanks to all those who sent replies. -- W. A. Harvey INTERNET: wah@cs.cmu.edu School of Computer Science CSNET: wah%cs.cmu.edu@relay.cs.net Carnegie Mellon University BITNET: wah%cs.cmu.edu%smtp@interbit Pittsburgh, PA 15213-3890 UUCP: ...!seismo!cs.cmu.edu!wah 412-268-7552