recursively search files for strings; list found files in sorted order

Eon Works | Scripts | Demo | About | Links

img
script: sfiles (download)
purpose: recursively search files for strings; list found files in sorted order
requires: standard GNU commands
version: 1.1
usage: sfiles [-hlm] -p "<pattern>" -s +|-<n> -a "<string [string..]>" [-o "<string [string..]>"] [-n "<string [string..]>"]
options:
 

     -p, \"<pattern>\", search file pattern as accepted by find&#39;s -name option.

         No case distinction is made.

     -s, +|-<n>, file size in bytes; +n for greater then n; -n for less then n;

         n for exactly n.

     -a, AND operator. Match files that contain all strings supplied to this 

         argument. No case distinction is made.

     -o, OR operator. Match files that contain at least one of the strings 

         supplied to this argument. No case distinction is made.

     -n, NOT operator. Do not match files that contain strings supplied to this

         argument. No case distinction is made.

     -w, list files in html format, where each file has a link to it&#39;s location

     -h, usage and options (this help)

     -m, manual

     -l, see this script"

manual:
 



DESCRIPTION



    sfiles is a searching tool for local text files. It recursively searches for

    specified strings in files. It supports AND, OR and NOT boolean operators.

    The string search is not case sensitive. The output consists of the sum of 

    each string found in a matched file. The results are sorted by the total AND

    strings found. An html formatted output is optional for easy location of 

    files using a browser.