home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware 1 2 the Maxx
/
sw_1.zip
/
sw_1
/
UTILS
/
WIZ251.ZIP
/
WIZ.DOC
< prev
next >
Wrap
Text File
|
1992-02-26
|
29KB
|
794 lines
WIZ version 2.5
by Ray Van Tassle
1020 Fox Run Lane
Algonquin, Ill, 60102
(708)-658-4941
February 25, 1992
WIZ program and manual copyright(c) 1990-1992 by Ray Van Tassle.
Abstract:
WIZ is a lightning-fast file finder. It will find file(s)
based on full wildcard specifications (more powerful than
standard DOS wildcard), and can also filter by file size
and date. It can:
* select only executable files (EXE, COM, BAT).
* select only archive files (ZIP, ARC, etc.)
* switch you to the disk\directory of a file that it found.
* execute a DOS command for each file it finds.
* look inside archives (ZIP, LZH, & ARJ)
* recursively look inside archives!
* Correct handling of the special files/directories created and
maintained by STACKER, Norton FILESAVE, and PCTOOLS DATA Sentry.
It will look on multiple disk drives for all matching
filenames. You can pre-specify several default lists of
disk drives for it to search.
WIZ program and manual copyright(c) 1990-1991 by Ray Van Tassle.
WIZ is shareware, NOT freeware!!!
You are granted a limited 21 day evaluation license. At the end
of that period, you should either delete it and stop using it,
or send in the registration fee of $15.
MANUAL
------
I was tempted to call this program YAFF (yet another file
finder), but I settled on WIZ. This is a funny acronym for
"where is". But it's also short for WIZARD, because it's so
fast it seems like magic, and it's filename matching is so
powerful.
It looks on one or more disks for all filenames (including
directories) that match the specified filename. By default, it
starts on drive C, and goes up until it runs out of disks.
It has been tested, and works, with DOS 3.x, including Zenith
DOS 3.30, DOS 3.31, DOS 4.01, DOS 5.0, and On-Track
partitioning software. DOS 3.31, 4.01, and 5.0 have large
(greater than 32MB) partitions with more than 65,536 sectors.
Zenith DOS 3.30 and On-Track have large partitions by virtue of
using large sectors (1024, 2048, or 4096 bytes, rather than
512 bytes).
WIZ normally prints out, for each matching file, the filename,
date, time, size, and path. The files are NOT ordered or
sorted. All "special" files (hidden, system) are
flagged with a left-pointing triangle after the filename.
Optionally, it will list the files in normal fully-pathed form
(e.g., C:\UTIL\PGMS\ABC.BAT), suitable for processing by a
program which expects normal filenames. When the found file
is inside an archive (-l flag), it will be listed in a form
suitable for the archiver (e.g.,
"C:\UTIL\PGMS\FOO.ZIP FILE.EXE")
I deemed that most of the time, people (including me) want it
to be FAST, rather than in some particular order.
As WIZ reads the disk, it tries to optimize the head
motion, so directories are not processed in order of path, but
in the order that WIZ thinks will be quickest. However, it will
generally look at the files in a directory before it looks at
the sub-directories. However (especially if you have
directories with lots of files and sub-directories), it may
show some files in a directory, then show sub-directories, then
show more files in the directory.
WIZ will ignore STACKER (tm) container files in the count of
files & MB's scanned. STACKER is a disk expander utility
that keeps a compressed pseudo-disk in a container file.
This file has attributes of RHS, and is named "STACVOL.???".
Likewise, WIZ will ignore the special hidden directories where
Norton's "FILESAVE" and PCTOOLS "DATAMON/SENTRY" move files that
have been deleted. These tools & their directories are a super
undelete, and they are reported by DOS to have been deleted, but
the respective utilities really just have them tucked away in a
hidden place. So WIZ treats these files as not being there, too.
PERFORMANCE & Comparison with other file-find programs
------------------------------------------------------
Some tests, run on a 10MHZ AT, searching for a non-existent
file on a large disk partitioned into drives C thru K,
8002 total files, 184MB in files, in 436 directories.
Search WIZ WHEREIS Norton FF
string V2.3 V4.0 V4.5
-------- ---------- ----------- ------------
zzz.zzz 0:13 1:32 1:42
*.zzz 0:15 2:00 (*) 1:51
*.*zz 0:17 2:00 can't
*.zz* 0:15 2:01 1:51
(*) file_specifier was `*.* "?.zzz" '
Looking inside archives (ZIP & LZH):
WIZ SST 5.2a
------- --------
24 archives, ?? files 0:13 0:18
418 archives. 4700 files 3:02 4:02
(Note: SST v5.2 is the new name for WHEREIS v5.2)
WHEREIS V4.0 (and some others) can look within more types
of ARC, ZIP, etc. files than WIZ handles. But WIZ is
much faster than any other file-finder (including Norton's),
and it's wildcard ability is much more powerful than most,
and easier to use than most others that are equally powerful.
WIZ is also much smaller than these other programs.
Norton FF v4.5 is 9K, WHEREIS v4.0 is 22K, WIZv2.0 is 10K
SSTv5.2a is 44K.
ERRORLEVEL exit codes
---------------------
0 = Normal exit.
1 = Normal exit. -g changes disk/path
2 = Bad command line.
255 = Internal error.
Error Messages
--------------
"Can't tell if FAT-12 or FAT-16. Assuming FAT-16!"
Just what it says. I've only seen this on networked
disk drives. If you know how to RELIABLY tell what
type of FAT a disk has (other than going thru DOS),
please let me know.
"malloc failed for FAT_buf!"
Can't allocate memory to read a FAT block. Most
likely an internal error.
"malloc failed for dir_sec_buf!"
Can't allocate memory to read in a directory sector.
Most likely an internal error.
"Sorry, out of memory!!!"
You lose.
"Can't open file:"
Failure to open an archive file. Most likely a disk
error. Run CHKDSK.
"Internal error in ZIP/LZH/ARJ file"
The data read from in archive file isn't as expected.
Most likely the archive has a new format, and WIZ
hasn't yet been updated. 'Course, the archive file
may be corrupted.
BUGS
----
No known bugs. However, WIZ mostly does not use DOS to
process a disk, so errors on my part, or a change in the disk
structure might break it. The most major bug reported was on
huge disk partitions under MS-DOS 4.01. This bug caused WIZ
to read a random block from the disk, and treat it as a
directory. It made a valiant attempt to march down all the
phony sub-directories, and would actually run for quite a
while before printing one of the "malloc failure" messages.
If you are having problems, try 1) use the "-v" switch, to
isolate the error to a specific disk, 2) use "-vv", to see
as it hits each sub-directory, 3) use "*.*" to see all the
files, and watch until it walks off the edge of the world.
Then call or write me.
Command Line format and Switches
--------------------------------
WIZ [disks:]file_pattern [-sN] [-dN] [-p] [-gN] [-x] [-m]
[-a] [-v] [-l[b][l]] [-cS] [-zN] [-?] [>output-file-name]
As usual, the stuff inside the square brackets "[]" are
optional and may be present or omitted. You do NOT include
the brackets in your command line.
The various fields and options may appear in any order, in
either upper or lower case.
The switch character can be either "-" or "/".
You can have more than one set of "[disk:]pattern", and it
does the correct thing. That is, it scans each set in turn.
So you can say: "WIZ c:pyro* cd:*.cfg *.ovr".
Except for size (-s) and date (-d), the options may be run
together.
For example: "WIZ -g20xp" is the same as "WIZ -g20 -x -p".
If you just invoke WIZ without any parameters, it gives you a
brief help line. For more info, include '-?'. For even more,
include '-??'.
If you leave out a pattern, but do have switche(s), WIZ assumes
that you want a pattern of "*".
Disk(s): & filename_pattern
---------------------------
1) [disks:]pattern
2) pattern
3) :pattern
With format 1, you specify the disk(s) you want it to look at,
followed by ":". It will look at those drives, in the order
you listed them. If you list the same one twice, it will look
at it twice. You can specify a range of disks by using a
dash--"C-F" is the same as "CDEF".
With format 2, it will look at all drives beginning with C. It
will stop when it hits a drive that it cannot read.
With format 3, it will look at all drives beginning with A. It
will stop when it hits a drive that it cannot read, except A &
B. If the floppy drive has a disk in, it will look at it,
otherwise it will ignore the floppy drive.
If you have only one floppy drive, WIZ will check to see if DOS
last used it as A or B, and will skip the other drive letter
(B or A).
You do not (and cannot) specify path or directory names,
because WIZ searches an entire disk.
Processing Disk(s) and Environment Variable
-------------------------------------------
You can over-ride the disks that WIZ looks at, and their
order, by making an environment variable "WIZ". Do:
"SET WIZ=floppy-disk-list:hard-disk-list". Example:
"SET WIZ=AB:C-M". What actually happens is that WIZ will
try to read all the disks to the left of the colon, then all
those to the right of the colon. Those on the left are
deemed to be floppies, and it will keep going if it can't
read one. Those on the right are deemed to be hard drives,
and it will quit on the first one that it can't read.
You may omit the "default" disk set by leaving a space after
the "=". This is most useful when you need only to put the
"/M" switch, as: "SET WIZ= /M".
If you specify disks on the command line, it will try to read
them all, even if it can't read one.
The list may be discontiguous, (e.g., "C-FL-M"). This is
mostly useful if you are on a network, which tends to make
the networked disks at the higher letters, and leaves a hole
before them.
Pre-defined Drive Sets
----------------------
You can actually have several pre-defined sets of disks to
search. If the disk-specifier on the command line is a single
digit (0-9), it will look for that specifier in the WIZ
variable. For example, you might say:
"SET WIZ=AB:C-F 1=CDEF 2=AB: 3=C-Z 4=C-Z:"
As above, those to the left of the colon are deemed floppies,
and WIZ will keep going if it can't read one; those to the
right are hard drives, and WIZ will quit if it can't read one.
However, if there isn't a colon, then they are ALL deemed to
be hard drives.
The command "WIZ z.z", will look on ABCDEF.
The command "WIZ 1:z.z", will look on CDEF.
The command "WIZ 2:z.z", will look on AB.
The command "WIZ 3:z.z", will look on all drives C-Z (and
will quit at the first on that it can't read).
The command "WIZ 4:z.z", will look on all drives C-Z (and it
will attempt to read each and every one of them).
The command "WIZ 9:z.z", will give an error message.
PATTERN:
--------
I call it "pattern" rather than "filename", because WIZ
does a full pattern-match against the actual filenames it
reads from the disk. The pattern has three special characters
(called meta-characters), plus all the other characters
possible in a filename.
1) "*" (star)
2) "?" (question mark)
3) "." (dot),
1) "*" This is the "rubber" wildcard meta-character. The
star will match as many characters as possible, from
none to the entire filename. It is "rubber", because
it will shrink & stretch to match as many characters
as required.
2) "?" This is the "single" wildcard meta-character. It will
match exactly ONE character in the filename.
3) "." This is the "separator" meta-character (it is NOT a
wildcard character).
If you specify a dot in the pattern, the disk filename
(and the pattern) is treated as having two parts,
one before the dot, and one after the dot.
Each part undergoes it's own pattern matching.
If you don't have any meta-characters in the filename pattern,
WIZ appends a "*" on the end of what you specified.
Proper pattern matching (like WIZ does) is almost a D.W.I.M.
(do what I mean) operation. DOS's wildcards are so primitive
that it is professionally embarrassing. Not only that, but the
pattern-matching subroutine in WIZ is only a couple of dozen
lines of code. And it's surprisingly fast.
To give some examples:
*A* means:
any file which has an A anywhere in it, on either side
of the dot.
Z* Any file that starts with a Z
(ZZBC.BAT Z.Z)
?. Any filename that has exactly one character in it, and
has no extent. (A. B. but not AB. or A.BAT)
?* Any filename that isn't totally blank.
A*T any file that starts with A and ends with T in the
extent. (ABCDE.BAT A.T AB.ERT but not ABCERT.)
A*T. any file that starts with A and ends with T, and
has no extent. (ABCERT. but not ABCERT.RST)
A*T.* any file that starts with A and ends with T, whether or
not it has an extent.
(ABCERT. ABCERT.RST ABCDET.COM)
A*B*Z.* any file that starts with A then somewhere to the right
has a B, then ends with Z, and has any extent.
(ABZ.BAT AMNOBPQRZ. ABYXZ.COM)
*.C any file with an extent of C
W*.C any file that starts with W and has a C extent. (W.C
WIZ.C WIZ14.C)
W*4.C any file that starts with W, ends with 4, and has an
extent of C.
???.C any file that has exactly 3 characters in the name, and
an extent of C.
Directories also participate in the filename matching. A lot
of other whereis programs don't tell you about directory names
that match. I find this annoying, because many times I can
remember the directory name (or at least part of it), but not
the file names. This is especially true for things that I
have downloaded. Since directories normally don't have an
extent (although they can), for matching purposes a directory
that does not have an extent is treated as if it has a blank
extent, so it has a dot. But when it is printed out, this
implied dot isn't printed.
POPDROP. will match the directory name "POPDROP"
and the filename "POPDROP.", but not "POPDROP.COM"
POPDROP.* will match all of the above
POPDROP will match all of the above, but also POPDROP2.COM
etc.
-s Size qualifier
-----------------
Files may be further filtered by their size. Either or both
minimum and maximum size may be specified. A file will match
only if it's size falls between the two limits, inclusive.
Note that a directory, while it is really a file, is not
considered to have a size, so directories will NEVER show up
if you give a size qualifier. This gives a way to never show
directories: just add "-s0". All other files have a size
that is greater than or equal to zero.
-s[low_limit][:hi_limit]
-s100 Files that are 100 or more bytes large.
-s:10000 Files that are 10000 or less bytes large.
-s500:600 Files whose size is greater than or equal to
500 bytes, and less than or equal to 600 bytes.
-s1000:1000 Files that are exactly 1000 bytes large.
-d Date qualifier
-----------------
Files may also be filtered by date. Either or both
lowest & highest date may be specified. A file will match
only if it's date falls between the two limits, inclusive.
-d[low_date][:high_date]
The format for date is MM/DD/YY or MM-DD-YY. The year
can be given as either "91" or "1991".
-d1/1/90 Files dated on or after Jan 1, 1990.
-d:12-31-87 Files dated on or before Dec 31, 1987.
-d1-1-90:12-31-1990 Files dated anytime in 1990.
-d12/12/90:11/11/90 No files---it's impossible for a file to
be dated after Dec 12, 1990 and before
Nov 11, 1990 (inclusive)
-p List in canonical pathname format
---------------------------------------
The matching files are listed in normal DOS format:
disk:\path\name.ext
If the "-l" flag ("look inside archives") is given,
the format is:
disk\path\archive-name.zip filename.ext
Date, time, size are not given. This type of list
is presumably going to be fed into a program as a
list of files, so directories will not be listed.
-g Go to directory
----------------------
This will change your path to the disk & directory of the
Nth file in the list of files that matched. If you omit
N (or N is zero), it will ask you at each match if that is
where you want to go.
If that file is a directory, WIZ will set the path to that
directory. On the other hand, if it is a file, WIZ will set
the path to be the directory that the file is in.
Obviously, if N is larger than the number of files that match,
nothing will happen.
-g5 Will change to the path of the 5th listed file.
-g1 Will change to the path of the first listed file.
-g Will ask you at each matched file if it should change
to the path of the listed file.
-x Executable files
----------------------
This switch will set a pre-filter, and select only executable
files (.BAT, .COM, .EXE) that pass the other filters (size,
date, pattern). For this to work properly, the pattern should
either not have a dot, or terminate with ".*" (because this is
just an additional filter, albeit one with three holes).
I added this because a lot of times I find myself looking for
a handy but seldom-used program, and I can never remember if
it's a COM or an EXE file. And if I put "*FOO*.*", WIZ lists
everything, including the directory, DOC, README, etc.
-m More (pause)
------------------
Act like "MORE"--pause and wait for a key to be hit after each
screenful of lines have been displayed. It checks how many
lines are actually displayed on the screen (25, 28, 43, 50, etc.)
-a Archive files
-------------------
This works just like "-x", except it's for archive files.
These are ZIP, ARC, LZH, ZOO, ARJ, PAK.
-v Verbose
-------------
If you have this flag once, WIZ will print the disk name when
it starts as it starts on a disk. If you have it twice
(-vv), it will also print the name of each directory as it
starts processing it. This is mostly useful for trouble
shooting, or to see a progress indication.
-l Look inside archives
--------------------------
This switch will make it look inside archives (ZIP, LZH, and
ARJ archives only), for a matching filespec. Note that all
the filters apply to the file INSIDE the archive, and NOT to
the archive itself. The disk list will, however, still
specify the disks to look at.
Both PKZIP and ARJ come with information on the internal
format of their archive files, including the header. Neither
LHARC nor LHA do, but it was pretty easy for me to figure
out. I do ZIP's because that is currently the most common
type of archive. LHA compresses smaller, but lacks a few
features, and is slower in compressing. ARJ is the BEST. It
packs 5% - 10% tighter than ZIP (but is slower in
compressing), and includes all the nice features of ZIP,
including encryption, comments, etc, and also can
automagically create a segmented archive, so you can put a
huge archive onto several floppy disks, without having to use
SLICE/SPLICE. It also comes with a handy utility to convert
any other archive type to ARJ's. I didn't do any other
archivers, because 1) I don't have information on the
internal format, 2) these three are the most common, and
best, and 3) I don't want WIZ to get any larger than
necessary.
-ll Look inside archives recursively
---------------------------------------
This switch will tell WIZ that you want it to also look
inside archives that are themselves in an archive. Naturally,
WIZ can only do this if the inside archive is "stored" (no
compression). With ZIP (and LHA) this is no problem, as PKZIP
normally cannot and will not compress a ZIP file when you
include it in another ZIP file. (Ditto for LHA). However, ARJ
can (and WILL) compress a ZIP file as it adds it to an ARJ file!!
'Course, it's pretty kinky to recursively store ZIPs in an
ARJ. You normally would not mix them this way. To see how
this works, do "WIZ -ll call_wiz*.*". This will show you the
various CALL_WIZ files that are in the WIZnn.ZIP, in
CALL_WIZ.ZIP.
In the output, these show up with a "@" where you would
normally see "\", which indicates that it's "kind of like" a
path. If this pseudo-pathname gets too long, a "+" is tacked
on at the end, instead of the actual filename; one for each
level that is being omitted.
You can also use the "-c" switch, but the filename that
replaces the "*" in the command won't make any kind of sense
to DOS, ARJ, LHA ZIP, etc., because of the "@" characters.
-b Both
------------
This switch is used with "-l" to look both at normal files,
and inside archives.
-zN Pass back information to calling program
------------------------------------------------
See "CALL_WIZ.DOC".
-c Execute a command
-------------------------
This lets you execute a DOS command for each matching file.
The format is '-cCOMMAND' or '-c COMMAND'. However, if the
COMMAND has any special characters (space, |, <, >, etc.) you
must enclose it in quotes: '-c"COMMAND"'.
Each occurance (if any) of the character "*" in the command is
replaced by the complete file-name (including disk and path).
WIZ will spawn a new copy of the command-line shell
(COMMAND.COM, 4DOS, etc.), and pass it the built command. The
one exception is that the command "del*" or "del *" (to
delete the file) is handled internally by WIZ itself. (Note
that you can use the form: '-cdel*', and you do not need a
space before the '*', nor do you need to enclose the command
in quotes.) For this command, WIZ will prompt you to confirm
each file to be deleted. (I did this because deleting files
is a handy thing to do, and it's quicker to do it inside of
WIZ than to spawn a shell to do it. But I'm no fool!! You
have to confirm that you want delete, for each file. No
way am I going to let it merrily delete every file on my
disk(s) just because I make one little mistake on the command
line!!) If you prefer to have the shell handle the file
deletions, use "erase *" or "delete *".
You can't do "-cdel*" along with "-l". If you have given the
-l switch, the '*" is replaced with the complete filename of
the archive (.ZIP, .LZH, .ARJ), a space, and then the
filename.
Examples:
-c"type *" -- type each matching file
-c"more <*" -- ditto, with a pause for each page
-c"copy * a:\" -- copy each matching file to A:
-c"set" -- display the environment at each
matching file.
-c"pkunzip *" -- extract matching files from a ZIP
archive.
Coming Attractions
------------------
An interactive screen interface.
It will gather the file names instead of just printing them
out. Then you will be able to sort by name, extent, disk,
date, size. You'll also be able to tag files and delete, copy,
move them, and find duplicates.
Plus other things I think of, or get suggested.
This is shareware, so I'm probably more interested and
receptive in hearing comments and suggestions than a commercial
software publisher would be. Just send them in, or give me a
call. I can't promise to fix bugs, or add specific features,
but I'll listen to everything. Even if you're cheap and
haven't registered.
BBS Support & New Versions
--------------------------
There is no "official" support BBS. However, I frequent a couple
of local BBS's:
Chicken Coop (708)658-1545 RIMENET =>THECOOP
Emporium (708)551-4275
Update History
--------------
1.6
Initial public release
1.7
Bug fixes
1.8
Changed "-g" operation. Quit as soon as we hit the correct
one. Sound an alarm bell when we set disk/directory.
1.81 (not released)
* Fix for huge disks. I tested with 100+ MB disk, but failed
to test with a nearly full disk. Result=BUG!! -- (overflow in
intermediate calculation, converting cluster to sector
number.) Thanks, Eddie, for running DOS 4.01 with one huge
>32MB partition--which all the gurus recommend against!
1.9
* Fixed bug in handling full root directory.
* Changes in walking the directory tree. Made it
non-recursive; changed the way I collect pathname to print.
* Added -c switch.
* Fix bug in handling a sub-directory that is exactly and
evenly full, with no next cluster.
1.91
* Slightly faster
* Added -a switch
2.00
* Slightly smaller and faster.
* Creeping featurism!!
* Added -l switch, to look inside archives
* Decided that the ability to look inside achives should
signify a new major version, so it's now 2.0
2.1
* Mod for stacker container files.
* Speeded up some filename checks (2 times in some cases)
2.2
* Better disk-name processing. Added WIZ environment
variable.
* Fixed bug introduced in 1.9 on pattern matching of
directory-names, with dot in pattern & no extent.
* Reset counts at the start of each path.
2.3
* Fixed matching of directory names (a very subtle bug!!)
* Added -z flag (for other programs to call WIZ).
* Changed -g0 to query at each matching file.
* Changed date format. Included seconds in the time.
* Added checking for the "other" floppy disk, if there is only
one configured on the computer.
2.4
* Changed order of size/date/time to be in the same as DIR.
* Re-fixed bug in directory matching. It was even more subtle
than I thought.
* Removed seconds from the time.
* Added -b switch, to allow it to look at normal files, and
inside archives, on the same pass thru the disk(s). This
was the single most requested modification.
* Added ability to recursively look in archives.
* If no pattern specified, but only switches, assume "*".
* Some more speed-up optimization; some minor bugs fixed,
including another one with HUGE disks.
* Added -m switch.
* Check for CTRL-BREAK flag (not CTRL-C!!), to bail out
quickly.
2.5
* Seems I made a "running release" of v2.4, (bad, bad me!)
This gets things back in sync.
* Allow missing default disk set in WIZ environment, and allow
"/foo" switches for RCD & WIZ.
********
Programming notes (if anyone is interested):
The way I scan thru the disk, it pretty much sweeps thru
the disk from front to back, without (much) hopping back &
forth. So it scans the 1st cluster of ALL the directories
and sub-directories on the disk, then makes a pass thru the
FAT (from start to end within the FAT), and so on.
This optimization of head movement really helps to speed it
up, especially if you don't have a fast disk. The
unfortunate side effect is that it looks at a directory one
chunk at a time, interspersed with chunks of other
directories. But it sure is fast!!
--------------------------
INVOICE / REGISTRATION
--------------------------
Sold to: ___________________________________________________
___________________________________________________
___________________________________________________
Date: ______________________________
============================================================
_____ copies of WIZ version 2.5 at $15 each $____________
_____ copies of RCD version ___ at $15 each $____________
DISCOUNT for registering both is
$5 off. Total is $25 instead of $30 ____________
TOTAL ENCLOSED....... $____________
Where did you get your copy of WIZ?
Shareware distributor name:___________________
BBS name: ____________________
BBS phone #: ____________________
Send this invoice and your check to:
Ray Van Tassle
1020 Fox Run Lane
Algonquin, Il. 60102
(708)-658-4941
=============================================================
Thank you for your support ............... Ray Van Tassle