Name
Subst —
\windows\system32\subst.exe
Synopsis
Create a new drive letter that is linked to a folder on your hard disk.
To Open
Command Prompt →
subst
Usage
subst [drive:] [path| /d ]
Description
Subst is a neat little utility that creates a new drive letter and actively links it to an existing folder on your hard disk. For example, type:
subst z: c:\my documents\downloaded music\led zeppelin
to create a new drive letter, z:, and link it to
the folder c:\my documents\downloaded music\led
zeppelin. When you open drive Z: in
Explorer, you’ll see the contents of the linked
folder; this is very useful if you access a particular folder
frequently but find Windows Shortcuts too limiting. For example, a
drive created with Subst allows you to access a file in the folder,
like this: z:\stairway.mp3. To disconnect a
Subst’d drive, type:
subst z: /d
Notes
Any drive letters created with Subst are forgotten when the computer shuts down. To have drives re-Subst’d every time you turn on your computer, write a batch file or WSH script (see Appendix C and Chapter 8, respectively) and place it in your Startup folder.
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access