Google
 

Trailing-Edge - PDP-10 Archives - decuslib10-06 - 43,50441/rev.hlp
There are 15 other files named rev.hlp in the archive. Click here to see a list.


                             HOW TO USE REV


REV is a general file manipulation program.  It can  be  used  to  copy,
rename, delete, and list files.  Wild file names and PPN'S are accepted.
REV supports two  command  modes:   "STAR"  mode,  in  which  a  command
involving  an unlimited number of files is given and then processed, and
"REV"  mode,  where  files  are  individually  listed  and   manipulated
according to the user's commands.

Upon running REV, the program first goes into STAR mode.  REV will  type
an  asterisk  ("*")  on  the  terminal  indicating that it is awaiting a
command.  The user may then type a command of the form:

*DEV:FILE.EXT[P,PN,SFD1,SFD2 ...]<NNN>/SWITCH                   ;OR
*DEV:FILE.EXT[P,PN]=DEV:FILE.EXT[P,PN]<NNN>/SWITCH

Several file specifications may be seperated  by  commas.   The  command
scanner  is  flexible,  and  will  take  many  variations  of  the above
examples.  For example, the following would be valid:

*[P,PN]FILE.EXT/SWITCH1/SWITCH2 DEV:

Where

"DEV:" is the device  used.   This  defaults  to  "DSK"  if  nothing  is
specifed.

"FILE" is the file name.  Wild cards may  be  used  here.   An  asterisk
("*")  indicates  that  any  unspecified  part  of  the name is wild.  A
question mark ("?") indicates a single wild  character.   Normally  only
alphanumeric  characters are accepted for the file name, but funny names
may be enclosed in double quotes ("""), which will cause all non-control
characters to be accepted.

"EXT" is the file extension.  The same wild card rules apply.

[P,PN] is the project programmer number enclosed in square brackets  and
divided  by  a  comma.   The  PPN  may  optionally  be  followed  by SFD
specifications seperated by commas.  An asterisk may be used to  specify
a  wild  project  or programmer number, and a question mark represents a
wild digit.  Wild cards apply to SFD specifications as they do  to  file
names.   If  not  specified,  this value normally defaults to the user's
default path except in the case of a file being renamed, in  which  case
the PPN defaults to the current path of the renamed file.  If either the
project or programmer number is omited, the project or programmer number
under  which  the  user  is  logged in is substituted.  The use of "[-]"
indicates the user's default path.

<nnn> represents an octal 3 digit  protection  code  enclosed  in  angle
brackets.  This is only required when specifying protection for a new or
renamed file.

Certain commands will imply wild cards for unspecified  file  names  and
extensions.   In general, if a REV function just lists information, then
unspecified file names  or  extensions  become  wild.   Functions  which
perform  action  on  the  specified  files  never  have  automatic  wild
substitution.  For example, while /LIST with  no  other  arguments  will
list all files, /DELETE will not delete all files!

Switches specify the type of action requested.  The  following  switches
are legal from STAR mode:

     AFTER    -  Files  are  not  processed  until  one   matching   the
     specifications  given  are met.  Every file found following that is
     processed.

     BACKSCAN    -  Causes  the  file  to  be  operated  on  before  the
     directory  file  which it is in can be operated on.  For example, a
     directory of [,,*] will list files on [,] before  files  on  [,,*],
     but the latter will be listed first if /BACKSCAN is used.

     CONFIRM   -  Causes confirmation of each file before it is  altered
     according  to  the  command  specifications.  Each file to be acted
     upon is listed, then "CONFIRM:  is typed, and  the  user  may  type
     "YES"  or "NO" (CRLF defaults to "NO).  If "YES" is typed, the file
     is altered as specified in the command line, if "NO" is typed,  the
     file is ignored.

     CODE   -  When used with the /COPY or  /TYPE  switches,  the  files
     transferred  will  be  coded according to the given password.  If a
     password has not been previously input, it will be requested.

     COPY   -  The file on the right side of the equals sign  is  copied
     to  the  specifications given on the left of the equals sign.  This
     switch is default when an equals sign is in the command.

     DELETE   -  This causes the specified files to be deleted.

     DIRECT   -  Gives a directory of the specified files.  This  switch
     is default when no equals sign is in the command line.

     EXIT   -  Exit to monitor level.

     FAST   -  Lists only the names and  paths  of  files  matching  the
     specifications.  This is a brief form of /DIRECT.

     HELP   -  Type  this  text.   /HELP:SWITCHES  will  list  available
     switches.

     INDIVIDUAL   -  This switch causes REV to enter REV mode.  For each
     file matching the specifications, a line of information followed by
     a colon is typed.  See the following section on REV mode.

     LIBRARY   -  Causes the PPN specified to become the user's  library
     ppn.   If no PPN is specified, then the present library, if any, is
     removed.  A library is a PPN that  is  automatically  searched  for
     files when the search in the specified path proved unsuccessful.

     LIST   -  The same as /DIRECT

     KILL   -  The same as /DELETE

     NOSCAN   -  This switch prevents files along higher levels  of  SFD
     nesting than the specified level from being returned.  For example,
     the  specification  *.*[,,*]  would  return  files  in   [,],   but
     *.*[,,*]/NOSCAN would not.

     PASSWO   -  This is the same as /CODE, except that a  new  password
     is always requested.

     PATH   -  Sets the user's default path to the specified path.

     NEW   -  Enables NEW on the user's path.

     SYS   -  Enables SYS on the user's path.

     NONEW   -  Removes NEW from the user's path.

     NOSYS   -  Removes SYS from the user's path.

     PROTECT   -  Protect the files with the specified octal  protection
     code.  If no code is specified, the default is 155.  This switch is
     the default if a protection code is specified.

     RENAME   -  Renames the files from the right  side  of  the  equals
     sign  to  the  specifications  given in the left side of the equals
     sign.  Wildcards on the left side  of  the  equals  sign  indicates
     specifications that do not change.  For example, the command 
     *X*=ABCDEF.GEH/RENAME
     would change the name of abcdef.geh to xbcdef.geh.

     SINCE:argument   -  Only processes files with creation dates  later
     than  the  specified  argument,  where  arguments may be one of the
     three, "TODAY", "YESTERDAY", or "LOGIN".  (/SINCE:LOGIN  means  the
     time  since  this  job  logged  in.)  If  no argument is given, the
     default is LOGIN.  In pre-602 monitors, it  may  be  impossible  to
     determine how long this job has been logged in.  In this case TODAY
     is substituted for the  argument.   Note  that  the  /SINCE  switch
     requires  all files considered to be looked up, adding considerable
     overhead to the program.  Also note that REV will read the internal
     creation date of the files, which is the absolute creation date and
     time, and this does not necessarily correspond to the date that the
     file  is  listed  as  having.   The  listed  date may be changed by
     rename, the internal creation date cannot.

     SUPER   -  Meaningful only with /RENAME  or  /DELETE.   Causes  the
     file  protection  to  be  lowered prior to the change, and restored
     afterwards, so that high-protected files can have their  attributes
     changed  without  going  through the trouble of protecting them low
     first.

     TYPE   -  The specified files are typed on the terminal.


When REV mode is entered through the /INDIVIDUAL switch, any file  found
to  be  matching specifications given is listed on the TTY followed by a
colon.  Then a single command may  be  given  to  alter  that  file.   A
carriage  return  leaves  the file unchanged, and the program goes on to
the next file.  The following switches apply to REV mode:

     COPY   -  The causes the file being reviewed to be copied into  the
     file specification given.

     DELETE   -  The reviewed file is deleted.

     EXIT   -  Exits to STAR mode.

     KILL   -  The same as /DELETE

     PROTECT   -  The file is given the specified protection.   This  is
     default if protection is specified with no other switches.

     RENAME   -  The file listed  is  given  the  new  name,  extension,
     protection,  or path.  This switch is default if a name, extension,
     path, or protection are specified with no other switches.

     SUPER   -  Protects the file with a  low  protection  before  doing
     rename.

     TYPE   -  Types the file on the terminal

     UP   -  Causes REV to go back up the list of  reviewed  files  when
     choosing the next file for review.


While the /TYPE or /DIRECT switch to REV is being processed, typing  two
control-C's  will  abort the command and keep the program in STAR or REV
mode.  This feature is implemented to allow the user to  use  the  /TYPE
switch  to  look at the contents of a file without being required to sit
through an  hour  of  typeout  or  control-O  the  output.   Typing  the
control-C's while the file types will bring the job back to command mode
immediately.

Here is an example of how REV can be used:


.RU REV

*.SFD           ;SHOW ALL FILES WITH THE EXTENSION OF "SFD"
DSKC:   [30,4666]
DAEMON  SFD      1  <775>   4-JUL-76
SYSINF  SFD      1  <775>   4-JUL-76
MAKPFH  SFD      1  <775>   4-JUL-76
CIT     SFD      1  <775>  28-AUG-76
DSKB:   [30,4666]
CIT     SFD      1  <755>  27-JUN-76
DAENEW  SFD      1  <775>  11-JUL-76
TWICE   SFD      1  <775>  28-JUL-76
SYSTAT  SFD      1  <775>  11-AUG-76
COMPIL  SFD      1  <775>  11-AUG-76
PSISER  SFD      1  <775>  26-AUG-76
MONGEN  SFD      1  <775>  26-AUG-76
*P*/F           ;GIVE A FAST LISTING OF ALL FILES WHICH START WITH "P"
DSKC:   [30,4666]
PR      MAC    PS      MAC    PSI     EXE    PSI     MAC   
PSI     DDT    
DSKB:   [30,4666]
PSISER  SFD    
*FOO.SFD=NUL:   ;CREATE THE FILE FOO.SFD
NUL
*[,,FOO]/PATH   ;PUT MY DEFAULT PATH INTO FOO
*[-]            ;WHAT FILES DO I HAVE ON MY DEFAULT PATH?
? ALL FILES REJECTED  DSK:*.*[30,4666,FOO]
*;NONE
*=HLPN:*.*      ;COPY ALL FILES FROM HLPN: TO MY DEFAULT PATH
DSKN:   [2,5]
DECUPD  HLP   
FILDAE  HLP   
DBMEND  HLP   
*;THE FILES THAT WERE FOUND WERE LISTED.
*[-]            ;NOW WHAT FILES DO I HAVE?
DSKC:   [30,4666,FOO]
DECUPD  HLP      2  <055>   5-SEP-76
FILDAE  HLP      1  <055>   5-SEP-76
DBMEND  HLP      2  <055>   5-SEP-76
*/I             ;ENTER REV MODE FOR ALL FILES ON MY DEFAULT PATH
DSKC:   [30,4666,FOO]
DECUPD  HLP      2  <055>   5-SEP-76  : X       ;RENAME TO X.HLP
FILDAE  HLP      1  <055>   5-SEP-76  : <333>/UP;FIX PROT, GO BACK
X       HLP      2  <055>   5-SEP-76  :         ;DON'T CHANGE THIS
FILDAE  HLP      1  <333>   5-SEP-76  : /K      ;TRY TO DELETE
? RENAME ERROR(2) PROTECTED
FILDAE  HLP      1  <333>   5-SEP-76  : /K/S    ;WAS PROTECTED, DO SUPER
DBMEND  HLP      2  <055>   5-SEP-76  : Z/COP   ;COPY TO Z.HLP
**.*/K          ;NOW DELETE ALL FILES ON PATH
DSKC:   [30,4666,FOO]
X       HLP   
DBMEND  HLP   
Z       HLP   
*;ALL LISTED FILES WERE DELETED.
*[,]/PATH       ;GET MY PATH OUT OF THIS SFD
*FOO.SFD/K      ;DELETE SFD
DSKC:   [30,4666]
FOO     SFD   
*^Z
EXIT