Next: , Previous: , Up: Commands   [Contents][Index]


4.6 Mcd

The mcd command is used to change the mtools working directory on the MS-DOS disk. It uses the following syntax:

mcd [msdosdirectory]

Without arguments, mcd reports the current device and working directory. Otherwise, mcd changes the current device and current working directory relative to an MS-DOS file system.

The environmental variable MCWD may be used to locate the file where the device and current working directory information is stored. The default is $HOME/.mcwd. Information in this file is ignored if the file is more than 6 hours old.

Mcd returns 0 on success or 1 on failure.

Unlike MS-DOS versions of CD, mcd can be used to change to another device. It may be wise to remove old .mcwd files at logout.