[1m

         SF                       USER COMMANDS               Version 2.0


         NAME         
[22m              SF - Search File: a flexible file finder 

[1m         SYNOPSIS         
[22m              SF P=PAT/a  pattern  DP=DIRPAT/k  TO/k  S=SINCE/k  U=UPTO/k
                 A=ARCHIVES/s   B=BLOCKS/s   D=DIRS/s  F=FILES/s  SHORT/s
                 NA=NOARC/s    NB=NOBANNER/s   NC=NOCOLOR/s   NI=NOINFO/s
                 NR=NOROOT/s NS=NOSORT/s NT=NOTOTAL/s L=LFORMAT/k 

[1m         DESCRIPTION         
[22m              SF  searches  for  files  or  directories into any AmigaDOS
              legal  device.   The  searching  is  done starting from the
              device's   root   directory   and   going   down  into  its
              subdirectories.  The  searching process also look for items
              into   archive   files  generated  by  various  compressing
              tools.   Archive  files  ending with a .ARC, .LHZ, .ZIP and
              .ZOO   extension  are  currently  supported.  To  use  this
              program,  you need ARP.library 1.3 (rev. 39.1) or higher in
              your LIBS: directory.  

[1m         THE OUTPUT DISPLAY       
[22m              SF,   using   the   default  options,  displays  files  and
              directories using the following template: 

                   [name] [size/type] [day] [date] [time] 

              A  number  of  options  (explained  below)  are provided to
              select  a  particular  set of files (or directories) and to
              alter  the output display format . It's possible to use the
              AmigaDOS  standard  operators '>' and '>>' or the TO option
              to  redirect  the  output. A description of each one of the
              above elements is given below.  

[1m              name         
[22m                   The name of the file or directory.  

[1m              size/type         
[22m                   This  field  represents  the size of the file in bytes
                   (or  in  blocks,  if  the  BLOCKS option is used). The
                   string   _(_d_i_r_)   will   be  displayed  if  name  is  a
                   directory.  

[1m              day         
[22m                   The   day   of  the  week  of  the  creation  or  last
                   modification date of the directory or file.  

[1m              date         
[22m                   The  date  of the creation or last modification to the
                   directory  or  file.  The  format is determined by the
                   value  of  the ARP's environment variable _d_a_t_e_f_o_r_m_a_t :
                   see  the  ARP  User's  Manual  for  legal  values  and
                   meaning of this variable.  




         ©1989 by Andrea Suatoni    25 Nov 89                      Page 1
[1m

         SF                       USER COMMANDS               Version 2.0


              time         
[22m                   The  time  of the creation or last modification to the
                   directory or file.  

              The  first  time a specified file or directory is found, SF
              displays  a header specifying if the item is contained in a
              directory  or  in  an  archive  file.  At  the  end  of the
              searching  process, totals are displayed stating the number
              of  directories  found,  the  number  of files found, their
              total  size  in  bytes  and  in  blocks.  At any time, it's
              possible  to  interrupt  the program pressing the Control-C
              or  Control-D  keys:  in  this case, a _S_F_:__*_*_*__B_R_E_A_K string
              will  be  displayed  and  no  totals will be reported. Note
              that  all other messages (including copyright message) will
              not  affect  the  output  redirection  and  will  always be
              displayed on screen.  

[1m         SELECTING DIRECTORIES AND FILES      
[22m              There   are  many  ways  to  select  a  particular  set  of
              directories  or  files  (or  both).  Many  options  can  be
              combined  together with few exceptions. As noted before, by
              default  the  searching  process  starts  from  the current
              device's  root  directory,  unless otherwise specified. See
              the examples section for some examples.  

[1m              P=PAT pattern        
[22m                   This  is  the  only required parameter. By it, you can
                   specify  which  set  of directories or files to search
                   for.  ARP  1.3  wildcards  and  character  classes are
                   fully    supported,    as   well   standard   AmigaDOS
                   wildcards.   The  PAT keyword is optional and required
                   only  if  positional  parameter  parsing is needed. If
                   neither  a  device  nor  a directory is specified, the
                   searching   process   will   start  from  the  current
                   device's root directory.  

[1m              DP=DIRPAT         
[22m                   This  option  is  useful when you want to search a set
                   of  directories or files only in a restricted range of
                   directories  or  archives. As for PAT option, both ARP
                   1.3  and  AmigaDOS  wildcards  are  supported, but you
                   cannot specify a device.  

[1m              S=SINCE date        
[22m                   This  option  selects only directories and files which
                   have   been  created  or  modified  on  or  later  the
                   specified  date.  You may specify the date accordingly
                   with  the  format  specified  by the ARP's environment
                   variable  _d_a_t_e_f_o_r_m_a_t  or  using  a  word  like  TODAY,
                   YESTERDAY  or  any  week day name. This filter applies
                   only  to  directories or files already selected by PAT
                   and DIRPAT options.  




         ©1989 by Andrea Suatoni    25 Nov 89                      Page 2
[1m

         SF                       USER COMMANDS               Version 2.0


              U=UPTO date        
[22m                   This  is  the inverse of the SINCE option. Directories
                   and  files  will be selected only if their creation or
                   modification  date is equal or less than the specified
                   date.  As  for  SINCE  option,  this filter is applied
                   only  to  directories or files already selected by PAT
                   and DIRPAT options.  

[1m              A=ARCHIVES         
[22m                   Forces  SF  to search for specified patterns only into
                   archive   files.   Default  is  to  search  into  both
                   subdirectories  and  archive  files.  This  option  is
                   incompatible with both DIRS and FILES options.  

[1m              D=DIRS         
[22m                   Forces  SF to select only directories specified by the
                   given  patterns.  No files will be searched for.  This
                   option  is  incompatible  with both ARCHIVES and FILES
                   options.  

[1m              F=FILES         
[22m                   Forces  SF to select only files specified by the given
                   patterns.  No  directories will be searched for.  This
                   option  is  incompatible  with  both ARCHIVES and DIRS
                   options.  

[1m              NA=NOARC         
[22m                   Forces  SF  to  not search for specified patterns into
                   archive files.  

[1m              NI=NOINFO         
[22m                   Forces  SF  to  not  select files whose names end with
                   _._i_n_f_o   extension,   regardless  any  possible  search
                   patterns.  

[1m              NR=NOROOT         
[22m                   Forces  SF to not start from the current device's root
                   directory.   If   a  device  and  or  a  directory  is
                   specified  within  the PAT parameter, this option will
                   have no effect.  

[1m         ALTERING THE OUTPUT DISPLAY FORMAT     
[22m              The  options  below  allow  you  to alter the format of the
              output   display.   They  can  be  freely  mixed  with  few
              exceptions.  

[1m              B=BLOCKS         
[22m                   Displays  file  sizes in blocks, rather than bytes. SF
                   computes  sizes  for  files contained into archives as
                   done  by  FFS (Fast File System), adding to the files'
                   actual  sizes  the  extra  blocks  required for a file
                   header  and  for  extension blocks, if needed. This is
                   useful  if  you want to know if a file, once extracted
                   from  an  archive,  will  fit  into  a disk. Note that


         ©1989 by Andrea Suatoni    25 Nov 89                      Page 3


         SF                       USER COMMANDS               Version 2.0


                   devices  mounted  with  OFS  (Old File System) require
                   more  blocks for files storage than those mounted with
                   FFS.  

[1m              L=LFORMAT string        
[22m                   This  option  will  allow you to specify output format
                   with  greater  flexibility.  _s_t_r_i_n_g is an ASCII string
                   in  which the '%' character has a special meaning when
                   associated  with  another character. Here is a list of
                   the legal sequences.  Note that case is significant.  

[1m                   %b         
[22m                        Outputs the size of a file in blocks.  

[1m                   %D         
[22m                        Outputs  the  day  of the week of the creation or
                        last   modification  date  of  the  directory  or
                        file.  

[1m                   %d         
[22m                        Outputs   the   date  of  the  creation  or  last
                        modification to the directory or file.  

[1m                   %f         
[22m                        Outputs the name of a directory or file.  

[1m                   %P         
[22m                        Outputs  the  name of the directory or file found
                        tacked on with its full pathname.  

[1m                   %p         
[22m                        Outputs  the pathname a directory or file belongs
                        to.  

[1m                   %s         
[22m                        Outputs the size of a file in bytes.  

[1m                   %t         
[22m                        Outputs   the   time  of  the  creation  or  last
                        modification to the directory or file.  

[1m                   %%         
[22m                        Outputs the '%' character.  

                   Also,  the  standard  AmigaDOS escape sequences _*_N and
                   _*_E  are  available  to output ASCII newline and escape
                   characters.  Note  that under ARP 1.3 environment, the
                   '*'  AmigaDOS escape character may be substituted with
                   another  character  (for  example, the '\' character).
                   Any   other   character   will  be  displayed  without
                   translation.  Specifying  an illegal '%' sequence will
                   cause  a warning message and the default output format
                   will  be re-selected. This option is incompatible with
                   the SHORT option.  


         ©1989 by Andrea Suatoni    25 Nov 89                      Page 4
[1m

         SF                       USER COMMANDS               Version 2.0


              NB=NOBANNER         
[22m                   Doesn't  display the copyright note. Useful for script
                   files.  

[1m              NC=NOCOLOR         
[22m                   Doesn't use ANSI control codes for program output.  

[1m              NS=NOSORT         
[22m                   Doesn't  sort  directories  and  files.  Default is to
                   sort   both   directories   and   files  in  ascending
                   alphabetic  order,  displaying  directories  first and
                   then files.  

[1m              NT=NOTOTAL         
[22m                   Doesn't display totals report.  

[1m              SHORT         
[22m                   Displays  directories  and files tacked on with theirs
                   full   pathname.  This  option  is  incompatible  with
                   LFORMAT option.  

[1m              TO pathname        
[22m                   Allows   to  redirect  program  output  to  any  legal
                   AmigaDOS  device.  This is useful if, for some reason,
                   you   cannot   redirect   output  using  the  standard
                   AmigaDOS  operators  '>'  and  '>>'.  Note  that  this
                   option will override any other output redirection.  

[1m         EXAMPLES         
[22m[1m              SF *        
[22m                   This   will   search  for  any  directories  or  files
                   contained  in  a  subdirectory  or in an archive file,
                   starting  from  the  current  device's root directory.
                   Useful  if you want to have a sorted list of an entire
                   disk or logical device.  

[1m              SF df0:mydir/*        
[22m                   This   will   search  for  any  directories  or  files
                   contained   in   the   _d_f_0_:_m_y_d_i_r   directory   or   in
                   subdirectories   or   archive   files   contained   in
                   _d_f_0_:_m_y_d_i_r .  

[1m              SF [abc]* DIRPAT [def]*      
[22m                   This  will search for directories or files whose names
                   begin  with  the character _a , _b or _c (or _A , _B or _C )
                   contained  in  subdirectories  or  archive files whose
                   names  begin  with  the character _d , _e or _f (or _D , _E
                   or _F ).  

[1m              SF myfile SINCE Monday UPTO Yesterday    
[22m                   This  will  search  file  (or directory) _m_y_f_i_l_e in all
                   subdirectories  and archive files only if its creation
                   or  modification  date  is  equal  or higher than last
                   Monday   and   up  to  (and  including)  the  date  of


         ©1989 by Andrea Suatoni    25 Nov 89                      Page 5


         SF                       USER COMMANDS               Version 2.0


                   yesterday.  

[1m              SF /a#? DIRPAT *.zoo FILES NOINFO LFORMAT "File %f 
[22m                   This  will  search  any file (not directories!), whose
                   name   begin   with   _A   or  _a  ,  contained  in  any
                   subdirectory(!)  or  archive  file  whose  names match
                   with  _*_._z_o_o  pattern.  Every file with _._i_n_f_o extension
                   will  be  discarded  and  output  format  will be like
                   this: 

                        File avail on DH0:Archive/Commands.zoo 

                   The  searching  process  will  start  from  the parent
                   directory   of  the  current  directory.  If  no  such
                   directory  exists,  an  error will be generated.  Note
                   that  NOROOT  option would have no effect in the above
                   command line.  

[1m         ADDITIONAL NOTES        
[22m              SF  has  been  developed with Lattice C Compiler 5.04 using
              Lattice  standard  resident  startup code. For this reason,
              SF  could  be  made  resident  under a wide number of shell
              environments.   Test  have  been  done  successfully  under
              WShell  environment  using  Bill  Hawes' RESI command. Note
              that  some  compressing  tools are able to pack directories
              into  archive  files:  however,  SF  is not able to display
              them, although it will find files contained in them.  

              SF  is  a  _s_h_a_r_e_w_a_r_e  product and is _N_O_T__I_N__P_U_B_L_I_C__D_O_M_A_I_N .
              Please read file _Y_o_u__M_U_S_T__R_e_a_d_M_e for distribution policy.  

[1m         CREDITS         
[22m              I  wish  to  thank many people that helped me in developing
              SF. First of all, many thanks to: 

                   Marco Ciuchini
                   Andrea de Prisco
                   Roberto Pratesi

              for  their  suggests and hints. Also thanks to all users of
              version   1.0   that   persuaded   me   in  continuing  the
              development  of  this new version. Lastly, a mention to the
              following people for their beautiful products: 

                   ARP authors   for their ARP.library
                   Bill Hawes    for his WShell and ARexx
                   Lattice Inc.  for their C compiler package









         ©1989 by Andrea Suatoni    25 Nov 89                      Page 6

