
Managing a DOS File System
114088 Rev. A 5-13
Examples:
Renaming a File or Directory
Use the rename command to change a filename or directory name.
If you specify a path to the file or directory, the file is moved to the new directory.
The new file or directory must reside on the same diskette as the original. You can
use the wildcard characters
* and ? to rename files and directories with the
character strings you specify. Enter the following to rename a file or directory:
rename
<old_name> <new_name>
Examples:
If you enter: The system:
rmdir \logs\L_6_23
Deletes the subdirectory called L_6_23 in the logs
path.
rmdir logs
Deletes the subdirectory called logs.
Note: You cannot rename a file whose attributes are h (for hidden) or
s (for system). Refer to the “Changing File Attributes
” section, later in this
chapter, for instructions on changing these protections.
If you enter: The system:
rename new.cfg old.cfg
Changes the file named new.cfg in the present
working directory to old.cfg.
rename *.cfg *.arc
Changes all filenames with a .cfg extension to
have a .arc extension in the present working direc-
tory.
rename \logs\l6_22.log
\inv\span.log
Moves the l6_22.log file in the logs directory to
the inv directory and renames the file to span.log.
Komentarze do niniejszej Instrukcji