SRD - Sort Directory Utility SRD is used to produce a directory listing in alphabetical order, by name or by name and extension. It may either be used to just produce a listing or it may be used to sort the directory information permanantly(until new entries are made). Listings can be outputed to TI:(by default) or to a file. The listing files can be edited. Further HELP may be obtained by typing HELP SRD keyword where keywords are as follows. COMMANDLINE The SRD Command Line LIST Getting a fast directory listing SORT Alphabetizing your user directory SELECT Performing selective searches SWITCHES The switches available for use with SRD DATE Search for files by date 2 COMMANDLINE SRD uses the standard RSX command line, SRD [outfile=] [UICSPEC] [FILENAME.TYP] [/SW] All fields are optional. If all fields are omitted SRD will prompt. Where no outfile is specified SRD defaults to TI:, the user's terminal. Outfile may also be a disk filename(eg. DIR.LST). DEV is the device on which the directory exists. If omitted SRD defaults to the user's SY:. TI: = DK3:/LI and DK3:/LI both produce a listing of the User's UFD (User File Directory) on DK3:. A listing file produced by SRD may be editted for use as a command file. The TECO macros STRIP & GET are useful for this. If the "/SE" switch is omitted, the file-name/typ field is used as a file-name selector. All files that start with what is given will be selected. (SRD XYZ is the same as SRD /SE:XYZ*). 2 SWITCHES SRD has a variety of switches to aid in UFD and file maintanance. /DA[:DD-MMM-YY] Select Date /FU[:n] Full listing /LI [/-LI] Create an output listing [or not] /NE Negate the selection mode of /SE & /SV /NA Sort by filename as primary key, not TYP /SD Selective Delete (it will ask for each file) /SE:NAME.TYP Select by file name /SV:[n] Select Version /SY Include system UIC's in a wild-card UIC search /WB Write Back Sorted Directory 2 LI #LIST 2 FU #LIST 2 SV The SELECT VERSION (/SV[:n] ) switch restricts the listing of file names to only the "n" highest version. The default for n is 1. 2 DA #DATE 2 LIST A UFD may be listed alphabetically listed using two switches /LI A short listing( like /BR in PIP) /FU:n A full listing. The :n is optional and if specified is the width the listing is to be(i.e. /FU:80.) 2 WB #SORT 2 SORT A UFD may be sorted alphabetically (or at least until more files are added) by use of the /WB switch(Write Back). example: DK3:/WB will alphabetically sort the user's directory on DK3: 2 NE #SE 2 SELECT There are cases in which the user would like to have only part of his directory listed. For example all files beginning with 'B', or having the first three letters 'TSK', or having a '.BAS' extension. This may be done using the /SE switch. The format is /SE:xyz where xyz is any character string to search for. Wildcards (*) may be used to specify any name,extension, or version as a match. In addition the '?' may be used to indicate that any single character found in the specified position is a match. /SE:HEL???.CMD would list both HELBLD.CMD and HELASM.CMD. A subswitch /NE exists which causes the files selected with the /SE switch to be those which do not match, ie /SE:S/NE selects all files not beginnig with "s" for listing. 2 DATE SRD may be used to list only those files produced on a given date, after a given date, or before a given date. /DA list all files produced today /DA:DD-MMM-YY list all files created on DD-MMM-YY(14-JAN-78) /AF:DD-MMM-YY list all files created after DD-MMM-YY. /BE:DD-MMM-YY list all files created before DD-MM-YY. By combining the /DA with the /BE or /AF switch it is possible to select for all files produced on and before(after) a given date. 2 SD The SELECTIVE DELETE switch causes SRD to list the selected files to the list file, then read TI: and examine the first character entered. If it is "Y" or "y" the file is deleted. Any other response causes SRD to proceed without deleting the file. All previous options for selection may be used, A select string may follow the /SD to cause SRD to select those files. A subswitch /DE may be applied to /SD to tell SRD not to prompt but to go ahead and delete all the files after listing. If the listing is not desired, the /-LI switch may be used. 2 NA The /NA switch causes files to be listed in order of file name only.