Generated from C.65.00 /SYSADMIN/PUB/MYCICAT last modified on Sun Aug 29 15:08:37 2004
Back to Main Index
Purges (unlinks) one or more directories.
PURGEDIR [DIR]=dir_name [;CONFIRM] [;NOCONFIRM] [;TREE] [;NOTREE] [;USENAME] [;SHOW] [;SHOWERRORS] [;NOSHOWERRORS]
dir_name The name of the directory that is being purged (required). The dir_name is assumed to be an MPE name. HFS-named directories may be purged if dir_name starts with a dot (.) or a slash (/). If dir_name is an HFS name and ends in a slash, then all objects at all levels under, and including dir_name, will be purged, unless the NOTREE option is specified. Wildcarding is permitted. The dir_name cannot name root (/). USENAME This default option indicates that dir_name alone controls whether or not all levels of directories and files are deleted. If dir_name is an HFS name and ends in a slash (/), then it, and all objects under it will be deleted. If dir_name does not end in a slash (/), then only dir_name will be purged, assuming it is empty. USENAME only applies to HFS-named directories, and is ignored for MPE-named directories. TREE Causes all objects below and including dir_name to be purged. The dir_name may or may not end in a slash (/), with no error/warning reported. Since the MPE naming convention does not support a trailing slash (/), the TREE option is the only way to delete a non-empty, MPE-named directory in a single command. NOTREE Causes dir_name only to be purged if it is empty. If dir_name is an HFS name and ends in a slash (/), a warning tells you that NOTREE overrides the trailing slash (/). CONFIRM Asks you to confirm the directory purge. CONFIRM is the default for sessions and is ignored in jobs. NOCONFIRM Causes the purge of dir_name (and all objects under it for TREE purges) without the need to prompt. NOCONFIRM is the default for jobs. SHOW Displays to $STDLIST each file/directory under dir_name that was purged. Directory names are always displayed in an HFS syntax, even if the name was specified as an MPE name. SHOWERRORS Causes each lower-level error, which prevents an object below dir_name from being deleted, to be displayed on $STDLIST. The object (file or directory) name is shown, followed by the error message. By default lower-level errors are not displayed. NOSHOWERRORS Suppresses the display of low-level errors. NOSHOWERRORS is the default.
Purges the directory dir_name. The dir_name cannot name an MPE account, an MPE group, a file, or root (/). Dot (.) and dot-dot (..) can be specified, but cannot be purged. By default PURGEDIR deletes an MPE-named directory. This means that dir_name must follow all MPE naming rules, unless it is prefixed with a dot (.) or a slash (/). Since the MPE name syntax defines three levels, fully (or partially) qualified MPE-named directories can only be created under MPE groups. Unqualified MPE-named directories are created relative to the CWD. Directories do not support lockwords, file equations, or system defined filenames (e.g. $NEWPASS). If dir_name begins with a dot (.) or a slash (/), then HFS naming rules are enforced. The directory referenced by dir_name must be empty (except for dot (.) and dot-dot (..)) in order to be purged, unless a TREE purge is requested. A TREE purge may be requested as follows: Specify the TREE option (dir_name does not control a multi-level purge in this case). This is the only choice available if dir_name is an MPE name. If dir_name is an HFS name, ends in a slash (/), and the NOTREE option is not requested. The dir_name cannot reference root (/) because purging root is undesirable, and most likely is not what is intended. A file or directory will not be deleted if it is being accessed (opened); however, all non-accessed objects under dir_name will still be purged. A final "IN USE" error indicates that dir_name was not deleted because one or more children objects could not be removed. If CONFIRM is specified and your session is interactive, then you are prompted to confirm the purge of dir_name. This prompt occurs before any validation of dir_name is performed. If a NOTREE purge is requested, the following prompt is displayed: DIRECTORY dir_name TO BE PURGED? (YES/NO) Valid responses are: ``YES'', ``Y'', ``NO'', ``N'' (case insensitive). If a ``TREE'' purge is requested, the prompt is: PURGE ALL FILES BELOW AND INCLUDING dir_name? (ALL/NO) Valid responses are: ``ALL'', ``NO'', ``N'' (case insensitive).
The following examples purge "dir1", which is empty. PURGEDIR /MYACCT/MYGRP/dir1 PURGEDIR /MYACCT/MYGRP/dir1;NOTREE The following examples purge "dir1" and below. PURGEDIR /MYACCT/MYGRP/dir1/ PURGEDIR /MYACCT/MYGRP/dir1/;TREE
Commands: CHDIR, LISTFILE, NEWDIR, PURGE, PURGEGROUP, PURGEUSER Back to Main Index