Renaming Your Directories

If you wish to change the name of a file or directory, you can do so by using the RENAME command.

Earlier in this chapter we practiced renaming files from the FILELIST screen. You can use the same method to rename your directories from DIRLIST.

The format of the RENAME command is:
Rename  /  newdirid

First you type RENAME in the Cmd space. Then you continue typing the rest of the command right over the information that is already on the line, just as you did when you renamed a file. Press Enter to rename the directory.

Suppose you want to rename the MISC directory and call it the LIST directory. The DIRLIST display is currently showing on your screen. Therefore, you can move your cursor to the Cmd space next to the MISC directory and enter the following command. Be sure to leave a space before and after the slash.

Skip over ASCII art.

rename / .list
       │   │
       │   └─────> new directory name
       └────>  stands for yourid.MISC

The figure shows the command rename / .list, in which / stands for yourid.MISC and .list specifies the new directory name.

Your screen will look like this:

 yourid   DIRLIST  A0  V 319  Trunc=319 Size=4 Line=1 Col=1 Alt=0
Cmd   Fm Directory Name
      A  VMSYSU:yourid.
      -  VMSYSU:yourid.LEISURE
      -  VMSYSU:yourid.LEISURE.SUMMER
rename / .listU:yourid.MISC













1= Help       2= Refresh  3= Quit   4= Sort(fm)    5= Sort(dir)   6= Auth
7= Backward   8= Forward  9=       10=            11= Filelist   12= Cursor

====>
                                                            X E D I T  1 File
When you press Enter, your command is processed. You will then see this notice:
*     ** Discarded, Renamed, or Relocated **
When you press PF2 to refresh your screen, the new directory name, LIST, will replace the old name, MISC.

Press PF3 to quit the DIRLIST screen.

You can use the RENAME command to change the name of your own directories or files. You can also change the name of another user's file if you have write authority to the file and to the directory where it resides. (We will discuss write authority later in this chapter.)

You cannot use RENAME to move a directory to another location. For example, you could not rename the LIST directory to the LEISURE.LIST directory. If you want to move the LIST directory to below the LEISURE directory, you must use the RELOCATE command. (We will discuss RELOCATE later in this chapter.)

Note: When a directory is renamed, any ACCESS commands that you entered remain in effect. If you enter a QUERY ACCESSED command after renaming a directory that you accessed previously, the command display will show the new directory name.