REGULAR EXPRESSIONS IN VIRGE

Regular expressions are implemented by using standard regex features of
GNU libc. Matching against expressions in 'extensions' file is simple -
in a loop, Virge goes through all extensions, and tries to compile
(regcomp() function) each of them. In case of success, it then tries to
see if string (filename currently being examined) matches the
expression. If so, file is isolated.

Matching is done in case *insensitive* mode - so

test.exe
tEsT.eXe
TEST.EXE

will all be matched against "\.$exe" pattern.

You can 'test' the validity of regular expressions, by executing:

# virge -R

Virge will the try to compile (regcomp() function) each expression,
and report any errors. Note that Virge can only tell is regexp is
*valid* - not if it does what you want it to do :)

Sample 'extensions' file contains some simple regular expressions which
should be sufficient for simple setups - most of Winblows brain damage
should be filtered out.

Some examples:

\.exe$ = matches any file that ends with ".exe"
^cheap.* = matches any filename that begins with string "cheap"
^a.*z$ = matches any file that begins with "a" and ends with "z"
.{11} = matches any filename which is 11 characters long
^[a-z\.]+$ = matches any filename that contains letters from "a" to "z" and dot (".").

Refer to the regex documentation/books for more examples.
