LFIND.EXE accepts a list of files as input, and a string as one of
its parameters. It functions either as a filter and outputs only
the filenames containing the string, or it may output each filename
followed by the lines, if any, containing the string. Lines with
more than 255 characters are truncated before the search.
The input list is assumed to be the names of text files, but no
check is made except the filetype exclusion list.
(See '/N' under Parameters)
Parameters may be entered in any order. Duplicate or redundant
parameters are errors.
return (or enter) that can be put on the command line. Double
quotes may be included as a pair of double quotes,
i.e. in the parameter
string is allowed and is required. Empty strings are ignored.
/W or /w:
This causes each filename to be output. If
any lines; the line number followed by ': ' and the line are
output. The search continues to the end of file or ctrl-Z.
/Q or /q:
This is the same as /W except that after each file has been
searched, if the input list is not empty, the prompt
LFIND: continue (Y/N)?
is output to stderr. After 'Y', 'y' or enter, LFIND.EXE will
search the next file. After 'N' or 'n' (or ctrl-break or ctrl-C)
LFIND.EXE terminates. If stdin is a device, it is assumed to be
the user device, otherwise another handle is redirected to stdin
and stdin is redirected to stderr. If no handles are available,
the program terminates with the message:
LFIND: too many file handles
If stdout is not a device, the message
LFIND: "/Q" ignored
is output to stderr, and execution continues as if the '/W'
parameter had been used.
Only the names of files containing
search terminates when
/U or /u:
This switch causes LFIND.EXE to search without case sensitivity.
The search is case sensitive.
(space(s) between switch and filename are optional)
The file contains a list of filetypes not to be searched. Each
filetype must be on a separate line. Each line must have three
or fewer characters. Other properties of the file are not
checked. The filetype list should not contain a period or
trailing spaces. An empty line indicates an empty filetype.
Any lines after the first 200 are ignored.
If no /N parameter is used, the list is "EXE", "COM", "LIB",
"OBJ", "BIN". These are not included automatically if the
/N parameter is used.
With L.COM and LX.COM:
L D:\ .PAS .C /S/F | LFIND "fizzbin" | LX /Q
This searches drive D: from the root (D:\) including all
subdirectories (/S) for Pascal and C files (.PAS .C); and
generates a list of filenames with drive and pathnames, one
to each line (/F). This list is passed (|) to LFIND.EXE
which searches with case sensitivity (no /U) for the string
"fizzbin". The names of the files that contain the string
(no /W or /Q) are passed (|) to LX.COM. The files that remain
in the list ($0) may optionally (/Q) be edited (
More simply, optionally edit any Pascal and C files on drive D:
that contain the string "fizzbin".