DOS 2.0 Utilities Disk 5 (Feb 1992) : Seeker / Seeker.doc

Seeker v1.2
By Don Lloyd





What is Seeker?


	Seeker owes its existence mainly to a friend of mine who, after 
installing the Release 2 operating system on his 2500, whined 
continuously that it should have come with a file finder similar to 
the one that comes as a part of the OS on a certain other well-known 
platform...
	Seeker is basically a means of tracking down a file that you know 
you have somewhere on that jumbled, disorganized hard drive (or 
floppy, or whatever) of yours.  You can specify a where to search and 
what to search for, and can perform several operations on the results.
	Seeker is currently written using CanDo v1.5.  It's a nice 
system, but it's got a few limitations that currently make Seeker not 
quite as polished as I'd like it to be.  Hopefully upcoming versions 
of CanDo will address these.





Seeker is Shareware!


	In an effort to help fund future computer purchases (not to 
mention college, car insurance, food, etc.), I'm asking a $10 
shareware fee.  Feel free to try it out for 30 days or so.  If at the 
end of that time you feel it's a worthwhile piece of software, send me 
$10 (See the address below).  If not, well... stop using it.




Legal Garbage



	No warranty of any kind is expressed/implied.  Although I've gone 
to great efforts to make it harmless and bug-free, and by it's very 
nature it doesn't do anything "dangerous" like low-level disk 
accesses, I disclaim all responsibility for any loss of data, 
hardware, possessions, property, or life as a direct, indirect, or 
apparent result of the use of Seeker.  It's somebody else's fault.
	This program may not be distributed as part of a commercial 
product or included in any PD collection that is sold by a commercial 
organization for profit.  Other than that, it can be freely 
distributed via BBSs, networks, users' group disks, Fish Disks (Fred 
is my hero :-), etc.  The files Seeker, Seeker.cd, Seeker.doc, and
their associated icons must remain in the archive.  Please remember
that Seeker is shareware, not PD.





What's needed to run Seeker?


	Seeker should be small enough to run on just about any Amiga ever 
made, although I've never really tried it in less than a couple of 
megs :-).  It uses the Release 2 "Search" command, which should be 
located in a directory that's listed in your search path.  (C: is a 
good place).
	Two versions of seeker are included.  The standard Seeker is for 
anyone with a system fitting the above specifications.  Seeker.cd is a 
version that's compiled to make use of CanDo.library, for those who 
have it (unfortunately, it's not freely distributable, so if you don't 
have CanDo, you probably don't have the library).  This version is a 
much smaller file and takes advantage of a shared library.





Using Seeker


    Starting the Program

	Seeker can be started from the CLI or workbench.  There are 
several optional Tooltypes that can be set by WB users, as well as 
some command line options from the CLI.
	From WorkBench, just double-click the Seeker icon to get started.  
There are three optional tooltypes that can be added to the icon (note 
that in order for these to work, the program file _must_ be named 
Seeker; one of those CanDo quirks I mentioned above).  The tooltypes 
are as follows:


STARTDIR=[directoryname] --  The directory where you'd like 
                             Seeker to start by default.

SEARCHSUBS=[flag]  --  Toggle whether or not 
                       subdirectories of the current                                                                  
                       directory will be searched.  If [flag] = "NO", 
                       "0", or "FALSE", subdirs won't be searched.                                                                   
                       Default is to turn on subdir searching.

SORT=[flag]  --  Toggle whether or not to sort the list of found files.
                 Otherwise, functions the same as the SEARCHSUBS tooltype.


	So, for example, "STARTDIR = sys:" would make Seeker always 
display the root of sys: when it starts up.  "SEARCHSUBS=no" would 
keep it from looking through all the subdirectories in sys: when a 
search is started.
	From the CLI, Seeker can be started with several optional command 
line items:

seeker [start directory]/[pattern]  [SUBS | NOSUBS] [SORT | NOSORT]

	[Start directory] is analogous the STARTDIR tooltype above.  
[Pattern] tells Seeker what pattern to search for (see Pattern 
Matching info below).  SUBS/NOSUBS toggle sorting on and off, 
respectively.  SORT and NOSORT toggle sorting.  SUBS and SORT are 
really unnecessary, since they're the default settings, but I kept 
them in anyway just to make the CLI options look more impressive :-).



Searching for Files


	Seeker has to know several things before it can start a search.  
The first of these is the path where it will begin looking.  Unless 
specified via tooltypes or command line options, the directory from 
which the program was started will be the search directory at first.  
To change directories once the program has started, use the mouse to 
maneuver around the directory list by double-clicking the directory 
you'd like to change to.  Double-clicking "<<Parent>>" will move up 
one level.  Clicking on the rollo gadget in upper left of the window 
(the one labeled "Show:") will toggle between listing the 
subdirectories of the current directory and listing the available 
volumes.  Double-clicking on an item in the volumes list will take you 
to the directory listing for the root of the volume you've chosen.
	Your path selections will be reflected in the Path text gadget to 
the right of the directory list.  You may also make changes directly 
in the text box.  Pressing return while after making changes to it 
will have the same effect as if you'd manually used the list box to 
change to that directory (provided the directory actually exists).
	Next, you'll have to tell Seeker whether or not to search 
subdirectories.  You can change this via the "Subdirs" button.  Most 
of the time, this will probably remain on, unless you've got a _lot_ 
of files in a specific directory (a fonts: directory, for example, or 
that directory called "temp" that just keeps getting bigger but never 
goes away) that you'd like to search through.
	You'll also need to decide whether or not to sort the file list 
that results from your search.
	Lastly, Seeker needs to know the name of the file you're 
searching for, or a specific pattern to match while looking for files.  
Seeker accepts the AmigaDOS "?" and "#" wildcards, as well as the more 
industry-standard "*".  Eventually I'll probably add some more 
wildcard capabilities similar to those available via the Unix C Shell.
	Without going into much detail about using wildcards (it's 
already been done many times elsewhere), here are some examples:

	am??a   -- find all files starting with "am", followed by any two 
letters, and ending in "a".

	picture.i#f - find all files beginning with "pictures.i" followed 
by any number of occurrences of the letter "f"

	#?.txt  -- find all files beginning with and number and 
combination of characters but ending in ".txt"

	*.txt -- same as above - the "*" wildcard is just a different way 
of representing "#?".

    Once you've supplied all this information, click the "Search" button
(or just hit <Enter> while the cursor is in the pattern box) and the search
for files will begin.  All files that match the pattern will be displayed
in the long list box at the bottom of the Seeker window.  You may also
start it by choosing "Seek" from the "File" menu.



Operations on Filenames:

    
    Use the scroll bar and arrows to move around in the list of found
files.  Clicking on an item in the list makes it the currently selected
file, so any operation selected will be performed on that file.  The
operations are accessible via the column of buttons under the "Ops:"
heading.

 Copy
    Asks for a new name and location via file requester, then copies the
selected file under that new name/location.

 Move
    As Copy, but deletes original file.

 Delete
    Deletes selected file.  This button must be double-clicked to work (a
safety feature).

 CLI
    Opens a new CLI and CD's to the directory where the selected file is
located.  The only way I've discovered yet to get these new CLIs to
remember the global path is to put a "Path ..." line in s:shell-startup
that contains the path you want your shells to have.

 Run
    If the file is executable, run it.   

 Info
    Display a short list of information about the selected file.



Filing Results:


    By choosing the "Results --> File..." menu item from the "File" menu,
you can save the names listed from your last search into a text file.  A
requester will ask you for the name and location of this file.



Drag & Drop NewCLI

    
    Seeker provides a quick means of opening a new CLI in any directory.
Just drag any icon from the WorkBench onto the Seeker window and drop it.
A new CLI will open and CD to the directory where that file is located.
(Programmers: somebody please write a CLI command that will open the current
directory's Workbench window!)  As with the CLI button above, the path will
not be remembered unless you put a path statement in s:shell-startup.





History:



v1.2

- CLI switches added.
- Now cleans up temp files on exit.


v1.1

- "Delete" button now needs to be double-clicked.  Previously it was 
too easy to click delete by accident and lose a file you didn't mean 
to get rid of.

- Support for tooltypes in icon added.




v1.0

- Initial, limited, sorta beta release.





Plans for the future:

(Many of which will happen only provided:  a.) New features are added 
to CanDO, or b.) I get really ambitious and find the free time to 
rewrite the whole thing in C).



- ASL file requester.  CanDo's is, well, not very likable.

- Ability to choose between opening Seeker on WB, public, or custom
screen.

- Better info window.  Right now, due to some of CanDo's limitations, 
it's a bit of a kludge.  Microsoft would be proud :-).

- On-line manual via CBM's new hypertext help system.  Haven't yet 
seen it, but it sounds promising.

- Ability to define viewers/players for different file types.  For 
instance, when the file selected is an IFF pic, the user could click a 
"Show" button to look at it.

- ARexx port.

- Clipboard support (copy a list or an individual item from the "Files 
found:" box into the clipboard).

- Support for some more Unix-like wildcards.

- Ability to choose several paths at one time to search.



- Any other ideas?  Send 'em to me!






Please send me questions, comments, bug reports (Bugs?  What bugs?),
shareware fees, and gifts :-).  My US Snail address:

   Don Lloyd
   775 Fox Chase Circle
   Bear, DE 19701

I can be reached electronically through several means:

Internet: don@chopin.udel.edu
   (At least until my account disappears again)
GEnie: D.LLOYD7
AmigaNetwork BBS: (302) 323-1604  Username =  Don Lloyd.