PIP - THE RSX11M FILE UTILITY PIP (Peripheral Interchange Program) is a general RSX Utility which is used to 1) copy files from one device/[UIC] to another, 2) delete unneeded files completely from your User File Directory(UFD), 3) purge unneeded versions from your UFD, 4) merge two or more files into a single file, 5) provide a directory listing of the files on the user's UFD, 6) list a source file at the user's terminal(TI:) or LP:. Additional HELP may be requested by typing HELP PIP keyword where allowed keywords are COMMANDLINE Using the PIP command line COPY Copying files DELETE Deleting files DIRECTORY Obtaining a listing of one's files LIST Listing the contents of a file at the MERGE Merging two or more files together. PURGE Purging files SPOOL Spooling a file to the line printer. SWITCHES Information on PIP switches. LIST List of available switches /sw Specific information on /sw TRUNCATE TRUNCATING unused blocks from a text file. UNLOCK Unlocking a LOCKED file. 2 COMMANDLINE The general format of a command to PIP is outputfile/Sw1../Swn = inputfile1/Sw1...,inputfile2/Sw1.... where Sw1,..Swn are any number of switches. The switches are the commands to PIP which perform operations on the files. If switches are omitted PIP will copy an existing input file into an output file. If the file version number is omitted PIP uses the highest version number. PIP has many command switches but almost everyting one needs to do can be done with a very few switches. HELP with the RSX11M File Specifier may be obtained by typing HELP FILES. HELP on the following switches is available by typing HELP PIP SWITCH /sw where sw is one of the following AP, BL, CD, CO, DE, EOF, FO, FR, FU, LD, LI, ME PR, PU, RM, RW, SD, SP, SR, SU, TR, UF, UN, UP 2 WILDCARDS PIP allows a "wildcard" in its command structure. Any part of a standard RSX11M File Specifier(NAME, TYPE, VER, etc) may be replaced with a "*". An * signifies that any NAME, TYPE, or VERSION within a UFD can satisf the given command switch. 2 SWITCHES Basic PIP Switch Summary LI LIST THE CONTENTS OF A UFD *.*;*/LI OR /LI list all files PU PURGE (ie DELETE) ALL BUT THE HIGHEST VERSION NUMBER OF A GIVEN FILE (NAME.TYPE COMBINATION). GRAPH.*;*/PU purge all files with NAME GRAPH with any TYPE. DE DELETE THE SPECIFIED FILE CALC.FTN;77/DE delete CALC.FTN;77 from your UFD UN UNLOCK THE SPECIFIED FILE(files can be locked for access if a program using them is aborted) CALC.FTN;78/UN RE RENAME AN EXISTING FILE GRAPH1.BAS/RE=GRAPH.BAS rename the highest version of GRAPH.BAS to GRAPH1.BAS ME MERGE SEVERAL FILES SUMFIL.FTN=FILE1.FTN,FILE2.FTN/ME 3 LIST /AP Append /BL:n Block size /BR Brief List /CD Creation date /CO Force contiguous output /DE Delete /EOF Position EOF marker /FO Set file ownership /FR Free space /FU Full list /LD List delete /ME Merge /PR Set file protection /PU Purge /RM Remove directory entry /RW Rewind magtape /SD Selective delete /SP Spool /SR Shared Read /SU Supersede /TR Truncate /UF Transfer to correct UFD on wildcard copies /UN Unlock /UP Update 3 AP Specifying the /AP switch will append a file to an existing file, creating a file of one higher version. ex: PIP TEST.CMD/AP=XYZ.CMD will append XYZ.CMD to TEST.CMD creating a new version of TEST.CMD. 3 CO Specifying /CO forces the output file to be contiguous. 3 CD CREATION DATE. This switch allows you to preserve the creation date of a file when transferering(copying) the file. Obviously, this switch won't work during a 'Merge' type command. 3 BL Specifying /BL:n (n is number of blocks(octal), n. is number of blocks(decimal)) along with the /CO switch on the output file specifier forces a file to be contiguous and n blocks long. 3 EOF END OF FILE SWITCH. This switch allows you to alter the EOF position in a file. Under certain conditions(ie a system crash) a file will contain useful information but the EOF pointers will be wrong, preventing you from getting at it. The format of this switch is; filespec/EOF[:BLOCK:BYTE], [filespec/EOF:[BLOCK:BYTE]] The value of 'BLOCK' is the block number in which you wish to indicate EOF or the first unused byte of the block. If neither value is entered, the EOF will be palced at the last byte of the last block allocated to a file. This switch is local to each filespec and does not default rom left to right. 3 RW To rewind a magtape use the /RW switch on the input file. If used on the output file, the contents of the tape will be erased. 3 DE A file may be permantly deleted using the /DE switch. The file's version number must be explicit or the file will will not be deleted. 3 The free space available on a disk is shown by typing PIP DKn:/FR 3 FU The /FU switch provides a full listing of the user's directory. 3 LI The /LI switch provides a normal listing of the user's directory 3 LD LIST DELETE. This subswitch(use with /DE, /PU) displays those files deleted or purged using a /DE or /PU switch. example: PIP *.TMP;*/DE/LD THE FOLLOWING FILES HAVE BEEN DELETED: DK2:[304,17]A.TMP;1 DK2:[304,17]AA.TMP;1 3 /FO Often used with the /PR switch(setting protection word) the /FO switch sets the file ownership to the UIC the file is residing in. See the manual for further details. 3 NM NO MESSAGE. This switch supresses certain error messages. At this time only the FILE NOT FOUND MESSAGE is supresed. 3 ME The /ME switch can be used to specify the merging of several files, but it is not needed. 3 /PR Set file ownership word. Don't use this unless you know what you are doing. ex: filspec/FO/PR:[RWED,RWED,RWE,R] Used with /FO. 3 PU The /PU switch purges old version numbers of files from a user's directory 3 RE The /RE switch can be used to rename a file(give it a new name). 3 SP The /SP switch forces a file to be spooled. Any file with a name LP.LST, *.DMP, or *.MAP will be deleted after spooling 3 SD SELECTIVE DELETE. This switch allows you to selectively delete files. It will prompt you with a candidate filename from the class of files specified in the command line. Your response choices are the letters Y, N, G, and Q followed either by a carriage return or ^Z(control-Z). The following table describes the effect of each combination of letter and terminator. LETTER TERMINATOR OPERATION ------ ---------- --------- Y Delete this file and continue in this mode <^Z> Delete this file and exit from PIP. N Save this file and continue in this mode. <^Z> Save this file and exit from PIP. Q Save this file and return to command mode. <^Z> Save this file and exit from PIP G Delete this file and all remaining candidates and return to PIP command mode when done. <^Z> Delete this file and all remaining candidates. Exit from PIP when done. 3 SR SHARED READ. This switch allows you to copy(read) from a file that is currently open for write. No guarantee may be made about what you might get since the EOF pointers may be incorrect at the time you open the file. 3 SU A current file(name.ext.ver) may be superseded by a new file with the same version number by applying the /SU switch to output file. 3 TR TRUNCATE. This switch will truncate a file to its logical EOF. see also HELP TRUNCate 3 UN The /UN switch unlocks a locked file(one which was improperly closed). 3 UP Basically the same as the /SU switch. 2 COPY A file may be copied from disk to disk, disk to tape and back, or from one part of a disk to another by using the standard command one outfilespecifier=infilespecifier If a disk or [UIC] is not specified in a file specifier files are only copied from the users file area into the user's file area. example: DK3:=DK4:[377,40]REPORT.FTN OR =DK4:[377,40]REPORT.FTN Both these command lines will copy the file REPORT.FTN on [377,40] on DK4: onto the user's file area on DK3:. 2 DELETE A file may be permanently deleted from the disk. When this is done there is no way to recover the file. Deleting a file frees up disk space so that other files may be created. To delete a file using PIP, the version number must always be specified in the command line. If in PIP type filename/DE where filename =name.ext;ver If not in PIP type PIP filename/DE 2 /BR #DIRECTORY 2 /LI #DIRECTORY 2 /FU #DIRECTORY 2 DIRECTORY A user may obtain a DIRECTORY listing of all the files on his UFD(or a selected group of them) using PIP or SRD. SRD is faster but provides less information than PIP. For HELP with SRD, type HELP SRD. A fast directory listing is obtained with the /BR switch, a medium long listing(with block usage) with the /LI switch, and a full directory listing with the /FU switch. examples: /LI Lists all files and blocks used /BR Brief listing of all files /FU Full listing of al files *.FTN/LI Listing of all files with .FTN extensions with the highest version number. TARGET.*/BR Brief listing of all files named TARGET with any extension and with the highest version number. 2 SPOOL #LIST 2 LIST A file may either be listed at a user's terminal or SPOOLED to the line printer. To list a source file at your terminal type(if you are in PIP) TI: = filename or(if not in PIP) type PIP TI: = filename of LIST filename (via CCL) To SPOOL a file type(if in PIP) filename/SP or (if not in PIP) type PIP filename/SP. or SPOOL filename (via CCL) 2 PURGE Each time a file is edited, or created a version number 1 higher than the previous file with the same name and extension is given the file. To PURGE(delete all old versions but retain the most recent version) a file type (if in PIP) filename/PU (if not in PIP) PIP filename/PU 2 RENAME To RENAME a file attach the /RE switch to the outfilespecifier ie., outfilespec/re=infilespec The rename operation does not create a new file, it just changes the name of the infilespec to the name of the outfilespec. 2 MERGE Two are more files may be merged into a single file by using the command string outfile=infile1,infile2,infile3..... The order of the sources appearing in outfile is coresponds to the order of the input files. Use of the /ME switch is not required. 2 TRUNCATE TRUNCATING A FILE TO ITS LOGICAL END Each time a program requests disk block space, the allocation requests are granted in 5 block increments(by default). This feature is particularly noticible when using the editor. Envariably every edited file uses up from 1 to 4 blocks than it logically requires . This space may be recovered using the PIP utility. The /TR switch in PIP will lop off the unused blocks in any file using the syntax. PIP> filespec/TR (Where filespec = DEV:filename) If DEV: is omitted a default SY: is inserted for DEV:. The FILE SPECIFIER may be either a standard RSX file specifier or it may contain wildcards which are accepted in the following formats. name.* *.ext *.* If wild cards are specified, it is assumed that the version should also be a wild card. 2 UNLOCK A file which is improperly closed(ie a task aborts without closing a file), is LOCKED by the filing system. To use the file again, it must first be unlocked. To unlock a file type PIP filespecifier/UN The /UN switch will unlock the file. # UNKNOWN QUALIFIER The allowed qualifiers are; COMMANDLINE COPY DELETE (or /DE) DIRECTORY (or /BR, /LI, /FU) LIST MERGE (or /ME) PURGE (or /PU) SPOOL (or /SP) SWITCHES [/AP, /BL, /BR, /CD, /CD, /DE, /EOF] [/FO, /FR, /FU, /LI, /ME, /PU, /RM, /RW] [/SD, /SP,/SR, /SU, /TR, /UN, /UP] TRUNCATE (or /TR) UNLOCK (or /UN) WILDCARDS