HELP DIRECTORY — VMS 4.6
Provides a list of files or information about a file or group of
files.
Format:
DIRECTORY [file-spec[,...]]
Additional information available:
ParametersCommand QualifiersExamples
Parameters
file-spec[,...]
Specifies one or more files to be listed. The syntax of a file
specification determines which files will be listed, as follows:
o If you do not enter a file specification, the DIRECTORY command
lists all versions of the files in the current default directory.
o If you specify only a device name, the DIRECTORY command uses
your default directory specification.
o Whenever the file specification does not include a file name and
file type, all versions of all files in the specified directory
are listed.
o If a file specification contains a file name and/or file type and
no version number, the DIRECTORY command lists all versions.
o If a file specification contains only a file name, the DIRECTORY
command lists all files in the current default directory with
that name, regardless of file type and version number.
o If a file specification contains only a file type, the DIRECTORY
command lists all files in the current default directory with
that file type, regardless of file name and version number.
If you specify more than one file, separate the file specifications
with either commas or plus signs. You can use wildcard characters
in the directory specification, file name, file type, or version
number fields of a file specification to list all files that satisfy
the components you specify.
Command Qualifiers
Additional information available:
/ACL/BACKUP/BEFORE/BRIEF/BY_OWNER/COLUMNS
/CREATED/DATE/EXCLUDE/EXPIRED/FILE_ID/FULL/GRAND_TOTAL
/HEADING/MODIFIED/OUTPUT/OWNER/PRINTER/PROTECTION
/SECURITY/SELECT/SINCE/SIZE/TOTAL/TRAILING/VERSIONS
/WIDTH
/ACL
/ACL Controls whether the access control list (ACL) for each file is displayed. By default, DIRECTORY does not display the ACL for each file. If you specify both the /ACL qualifier and the /COLUMNS qualifier, the /COLUMNS qualifier is ignored.
/BACKUP
/BACKUP Selects files according to the dates of their most recent backup. This qualifier is relevant only when used with the /BEFORE or /SINCE qualifier. Use of the /BACKUP qualifier is incompatible with /CREATED, /EXPIRED, and /MODIFIED. /CREATED is the default.
/BEFORE
/BEFORE[=time] Selects only those files that are dated before the specified time. You can specify either an absolute time or a combination of absolute and delta times. See Section 2.5 of the VAX/VMS DCL Concepts Manual for complete information on specifying time values. You can also use the keywords TODAY, TOMORROW, and YESTERDAY. If no time is specified, TODAY is assumed.
/BRIEF
/BRIEF (default) Includes only the file name, type, and version number of each file to be listed. The brief format lists the files in alphabetical order from left to right on each line, in descending version number order. However, the /BRIEF qualifier, whether specified explicitly or in effect by default, is overridden whenever one of the following formatting qualifiers is specified in the command: /ACL, /DATE, /FILE-ID, /FULL, /NOHEADING, /OWNER, /PROTECTION, /SECURITY, or /SIZE.
/BY_OWNER
/BY_OWNER[=uic] Selects one or more files only if their owner user identification code (UIC) matches the specified owner UIC. Specify the UIC using standard UIC format as described in Section 7.1.1 of the VAX/VMS DCL Concepts Manual. If the /BY_OWNER qualifier is specified without a UIC, the UIC of the current process is assumed.
/COLUMNS
/COLUMNS=n Lists the files using the specified number of columns on each line of the display. By default, the number of columns in the brief format is four. However, you can request as many columns as you like. The number of columns actually displayed depends on the amount of information requested for each column and the DISPLAY value of the /WIDTH qualifier. The system will display only as many columns as can fit within the default or specified display width, regardless of how many columns you specify with /COLUMNS. The DIRECTORY command truncates long file names only when you have asked for additional information to be included in each column. The default file name size is 19; use the /WIDTH qualifier to change the default. When a file name is truncated, the system will display one less character than the file name field size and will insert a vertical bar in the last position. For example, if the file name is SHOW_QUEUE_CHARACTERISTICS, and if you requested DIRECTORY to display both file name and size in each column, the display for that file would be: SHOW_QUEUE_CHARACT| 120. The /COLUMNS qualifier is not available with /ACL or /FULL.
/CREATED
/CREATED (default) Selects files based on their date of creation. This qualifier is relevant only when used with the /BEFORE or /SINCE qualifier. Use of the /CREATED qualifier is incompatible with /BACKUP, /EXPIRED, and /MODIFIED.
/DATE
/DATE[=option]
/NODATE
Includes the backup, creation, expiration, or modification date for
each specified file. If you omit this qualifier, the default is
/NODATE. If you use the /DATE qualifier without an option, the
creation date is provided.
You can specify one of the following options with the /DATE
qualifier:
ALL Lists all four file dates, in this order: CREATED,
MODIFIED, EXPIRED, BACKUP.
BACKUP Lists the date of the last backup with each file.
CREATED Lists the creation date with each file.
EXPIRED Lists the expiration date with each file.
MODIFIED Lists the last date the file was written.
/EXCLUDE
/EXCLUDE=(file-spec[,...]) Any files that match the listed file specifications are excluded from the DIRECTORY operation. If you specify only one file, you can omit the parentheses. Wildcard characters are supported for file specifications. However, you cannot use relative version numbers to exclude a specific version. The file specification can contain a directory specification, but not a device specification.
/EXPIRED
/EXPIRED Selects files according to the dates on which they will expire. This qualifier is relevant only when used with the /BEFORE or /SINCE qualifier. Use of the /EXPIRED qualifier is incompatible with /BACKUP, /CREATED, and /MODIFIED. /CREATED is the default.
/FILE_ID
/FILE_ID Controls whether the file identification of the file is displayed. By default, DIRECTORY does not display the file identification, except in the /FULL display.
/FULL
/FULL
Lists the following items for each file:
File name
File type
Version number
Number of blocks used
Number of blocks allocated
Date of creation
Date of last backup
Date last modified
Date of expiration
File owner's UIC
File protection
File identification number (FID)
File organization
Other file attributes
Record attributes
Record format
Access control list (ACL)
The /FULL qualifier overrides the default brief listing format.
/GRAND_TOTAL
/GRAND_TOTAL Suppresses both the per-directory total and individual file information. /GRAND_TOTAL displays only the total line for all files and directories that have been selected. (See the /TRAILING qualifier for information on displaying directory totals.)
/HEADING
/HEADING /NOHEADING Controls whether heading lines consisting of a device description and directory specification are printed. The default output format provides this heading. When you specify /NOHEADING, the output appears in single-column format. In addition, the output contains the full file specification on every file. If you specify the /NOHEADING qualifier and also specify a value other than 1 with /COLUMNS, the number of columns you specify is disregarded. You may find the combination of the /NOHEADING and /NOTRAILING qualifiers useful in command procedures where you want to create a list of complete file specifications for later operations.
/MODIFIED
/MODIFIED Selects files according to the dates on which they were last modified. This qualifier is relevant only when used with the /BEFORE or /SINCE qualifier. Use of the /MODIFIED qualifier is incompatible with /BACKUP, /CREATED, and /EXPIRED. /CREATED is the default.
/OUTPUT
/OUTPUT[=file-spec] /NOOUTPUT Controls where the output of the command is sent. If you do not enter the qualifier, or if you enter /OUTPUT without a file specification, the output is sent to the current process default output stream or device, identified by the logical name SYS$OUTPUT. If you enter /OUTPUT with a partial file specification (for example, /OUTPUT=[JONES]), DIRECTORY is the default file name and LIS the default file type. If you enter a file specification, it may not include any wildcard characters. If you enter /NOOUTPUT, output is suppressed.
/OWNER
/OWNER /NOOWNER (default) Controls whether the file owner's UIC is listed. The default size of the owner field is 20 characters. If the file owner's UIC exceeds the length of the owner field, the information will be truncated. The size of this field can be altered by specifying /WIDTH=OWNER, along with a value for the OWNER field. For more information, see the description of the /WIDTH qualifier.
/PRINTER
/PRINTER Queues the DIRECTORY command output for printing under the name given by the /OUTPUT qualifier. If you specify /PRINTER without the /OUTPUT qualifier, the output is directed to a file named DIRECTORY.LIS, which is automatically queued for printing and then deleted.
/PROTECTION
/PROTECTION /NOPROTECTION (default) Controls whether the file protection for each file is listed.
/SECURITY
/SECURITY Controls whether information about file security is displayed. Using the /SECURITY qualifier provides the same information as the three qualifiers /ACL, /OWNER, and /PROTECTION together.
/SELECT
/SELECT=(keyword[,...]) Allows you to select files based on the /SELECT keywords. /SELECT=SIZE=MAXIMUM=n selects files that have fewer blocks than the specified parameter. /SELECT=SIZE=MINIMUM=n selects files that have more blocks than the specified parameter. /SELECT=SIZE=(MAXIMUM=n,MINIMUM=n) selects files whose blocksize falls within the range specified by the two parameters. By default, file selection is based on other criteria.
/SINCE
/SINCE[=time] Selects only those files that are dated after the specified time. You can specify either an absolute time or a combination of absolute and delta times. See Section 2.5 of the VAX/VMS DCL Concepts Manual for complete information on specifying time values. You can also use the keywords TODAY, TOMORROW, and YESTERDAY. If no time is specified, TODAY is assumed.
/SIZE
/SIZE[=option]
/NOSIZE (default)
Provides the file size in blocks used and/or allocated for each file
listed, according to the option you specify. If you specify /SIZE
without an option, the listing provides the file size in blocks
used. The options you can specify are:
ALL Lists the file size both in blocks used and blocks
allocated
ALLOCATION Lists the file size in blocks allocated
USED Lists the file size in blocks used
The size of this field can be altered by supplying the SIZE value of
the /WIDTH qualifier.
/TOTAL
/TOTAL Suppresses the listing of all individual file information and displays only the trailing lines, as described under the /TRAILING qualifier. By default, the output format is /BRIEF, which gives this total, but also lists all the file names, file types, and their version numbers.
/TRAILING
/TRAILING
/NOTRAILING
Controls whether trailing lines that summarize the following
information are output:
o Number of files listed
o Total number of blocks used per directory
o Total number of blocks allocated
o Total number of directories and total blocks used and/or
allocated in all directories (only if more than one directory is
listed)
By default, the output format includes most of this summary
information. The /SIZE and /FULL qualifiers determine more
precisely what summary information is included. If you omit /SIZE
or /FULL, only the number of files is displayed and possibly the
total number of directories, if applicable. If you specify the
/SIZE qualifier, the number of blocks is also displayed, according
to the size option selected (USED and/or ALLOCATION). If you
specify the /FULL qualifier, the number of files as well as the
number of blocks used and allocated are displayed.
/VERSIONS
/VERSIONS=n Causes the latest n versions of each of the files selected to be listed. If you omit the /VERSIONS qualifier, by default the listing includes all versions of each file. A value less than 1 is not allowed.
/WIDTH
/WIDTH=(keyword[,...])
Allows you to change the format of the directory display for four
elements: file name field width, entire display width, owner field
width, file size field width. If you specify only one keyword, you
can omit the parentheses.
DISPLAY=n Determines the total width for the DIRECTORY
display. The value of n can range from 1 through
255. The default value for n is 0, which means
that DIRECTORY sets its display width to the
terminal width. If the total width of the
display exceeds the terminal width, the
information will be truncated.
FILENAME=n Determines the width of the file name field. The
default value for n is 19. If you have requested
another piece of information to be displayed
along with the file name in each column, file
names that exceed the n parameter will cause the
line to wrap, after the file name field. (See
the /COLUMNS qualifier.)
OWNER=n Determines the width of the owner field. The
default value for n is 20. If the owner's UIC
exceeds the length of the owner field, the
information will be truncated.
SIZE=n Determines the width of the size field. The
default value for n is 6. If the file size
exceeds the length of the size field, the
information will be truncated.
Examples
1. $ DIRECTORY The DIRECTORY command lists all versions of all files in the current default disk and directory in the brief format. The heading identifies the disk and directory, and the trailing line gives the total number of files. 2. $ DIRECTORY/VERSIONS=1/COLUMNS=1 AVERAGE.* The DIRECTORY command lists only the highest version of each file named AVERAGE in the current default directory. The format is brief and restricted to one column. Heading and trailing lines are provided. 3. $ DIRECTORY BLOCK%%% The DIRECTORY command locates all versions and types of files in the default device and directory whose names begin with the letters BLOCK and end with any three additional characters. The default output format is brief, four columns, with heading and trailing lines. 4. $ DIRECTORY PEORIA:: This DIRECTORY command lists all the files cataloged in the directory associated with the default account being accessed at remote node PEORIA.