home *** CD-ROM | disk | FTP | other *** search
- Name: GFind
- Purpose: Comprehensive disc searching utility
- Author: GNU
- Porter: Andrew Brooks (arb@sat.dundee.ac.uk)
- Version: 4.1 (RISC OS beta release 1.02)
- Status: Distributable under the GNU License
-
-
- Introduction
- ------------
- Gfind is a port of GNU Find, a sophisticated tool for searching discs.
- See the manual page for full usage, but briefly:
- * gfind [paths] [predicates]
- Search disc starting from given path(s) looking for
- files that match given predicates.
- Default path is @, default predicate is -print.
- * gfind --help Show command line syntax and options.
- * gfind List all files under current directory,
- same as gfind @ -print
- * gfind $ -ls List all files on current filing system,
- displaying them in the same format as unix ls.
- * gfind -mtime -3 List all files modified within the last 3 days.
- (Use +3 for 'greater than 3 days ago').
- * gfind -type d List all directories
- * gfind -type f List all files
- * gfind -filetype fff -o -filetype obey
- List all files of type &FFF (Text) or Obey.
- * gfind ( ( -name o -prune ) -o ( -name f* -o -name p* ) ) -type f -ls
- List in full all files with names matching f* or p*
- but don't descend directories with the name 'o'.
- * gfind -exec fileinfo {} ;
- Execute the given command (fileinfo in this case)
- for each item, the {} are replaced by the pathname,
- the ; terminates the command to be executed.
- * gfind -iname fi* -throwback
- Find all objects with name beginning with fi and
- throwback their pathname to a suitable editor.
-
- A DDE interface is supplied but it only allows a simple subset of
- options to be used, hopefully the most common and useful. For more
- details see its Help file (select Help from the filer menu).
-
-
- Notes
- -----
- The -filetype and -throwback predicates are RISC OS extensions.
-
- Image files (eg. SparkFS or ArcFS archives) are treated as files for the
- purposes of operations like -type (ie. -type d returns false) but they
- are entered as directories when traversing the tree.
-
- Inode, device, user and group numbers are all zero.
-
- Atime and ctime use the value of mtime.
-
- Xargs and locate have not been ported.
-
- Link handling is unknown and a large number of options are untested.
-
- The RISC OS shell does not require filename patterns to be escaped, so
- for example you can say -name f* where on unix you need -name "f*".
- Likewise with command: {} and ; do not need to be escaped.
-
- Filename matching is case sensitive for -name but insensitive (like
- RISC OS) for -iname.
-
- Executing commands is slow due to the hoops that system() has to
- jump through. It should be safe to execute commands other than those
- built-in (ie. commands which use application memory) though.
-
- Throwback of filenames only is not possible so I have to fake an info
- message (the filename) on line one of the file.
-
- The previously selected directory will not be restored on RISC OS 2.
-
- The manual has not been updated with RISC OS modifications.
-
-
- RISC OS Port
- ------------
- Only minor modifications were necessary to port find to RISC OS.
- These included:
- * Use of a bug-fixed version of Paul Moore's utils library for stat().
- * Use of a fake set of unix header files for everything else.
- * Removal of inode and device number re-traversal checks.
- * Fake UNIX functions used for handling links, password and group files.
- * Some header file modifications and a custom config.h
- UnixLib was not used.
- Gunnar Zoetl's Public Domain throwback library was used, thanks Gunnar!
- One modification: call free(current_pathname) in throwback_processing().
-
-
- Bugs
- ----
- Any bugs found are most likely introduced by the porting process
- and should not be a reflection on the original GNU code. Please
- report them to the address below.
-
- In particular directory traversal (esp. on different filing systems)
- has not been thoroughly checked - I just replaced all '/' with '.'
- for directory separators.
-
- The -throwback predicate should prevent the automatic use of -print but it
- doesn't for a reason I have yet to find.
-
-
- Distribution
- ------------
- GFind is distributed under the GNU License, see the file COPYING
- for details. Source is not included but can be obtained from any
- good FTP site. Ask me if you want my modifications.
-
-
- To do
- -----
- Fix handling of image files? I think it is actually fine as it is.
- Allow xdev etc. to know about image files?
- Modify mtime to allow specification of time in floating point?
- Support for file links, such as those generated by Brian Brunswick's
- !Links application. Test with other file linking systems.
-
-
- History
- -------
- 1.02 beta arb Wed May 24 06:06:39 BST 1995 - preserve csd and psd
- 1.01 beta arb Mon May 22 21:34:31 BST 1995 - added throwback
- 1.00 beta arb Sat May 20 16:20:26 BST 1995 - first RISC OS beta
-
-
- Contact
- -------
- This port by Andrew Brooks:
- arb@sat.dundee.ac.uk (arb@ua.ndu.ac.uk, arb@comp.lancs.ac.uk)
- http://www.sat.dundee.ac.uk/~arb/
- If all else fails, via parents at:
- 7 Kennedy Close, Newton, Chester, CH2 2PL, UK.
-