retail An incremental logfile reader.

	What:

	This program is my attempt to write an intelligent incremental logfile
reading utility.  Other such utilities exist, but I could find none that would
handle changing/dynamic logfiles to my satisfaction.  So, having an itch of my
own, I scratched it.  This code is the result.

	In summary, something like the following, if run as a cronjob:
retail /var/log/messages | mail youremail@yourdomain.com
Will get you all the new entries which happen to show up in your
system log.  In addition, it will attempt to intelligently cope with any 
changes to the file in question, by verifying that the data at it's last known
position has not changed, and if it has it will search out that same data
wherever in the file it now resides.  Should this be also impossible, it will
resort to rewinding to the beginning of the file and reading the entire thing.

	Please check out the doc/* directory for more information on the
things you can/can't do with retail (like how to do them :).


	Why?:

	For all my Linux/UNIX life, especially as a SysAdmin, I've been up to 
my neck in logfiles.  I'm also a shell script junkie, and I've been writing
scripts to make my life easier (for logfiles, and everything else) for years.
I've used Craig Rowland's <crowland@psionic.com> handy little logtail program
in conjunction with logtool (one of my other projects) for a few years now.
However, I recently found myself in a position where I am monitoring a logfile
which changes fairly regularly, and logtail just wasn't coping with the 
situation.  So, I have written this program in an attempt to do two things: 
duplicate logtail's functionality, while adding intelligent handling of
logfiles which get edited and mucked with from time to time.

	Uses:

	I expect this program to have primarily one real use (although if it
suits other needs, by all means, use it for whatever you want).

	1.  As an engine for use by shell scripts and/or cronjobs to read new
	    entries in logfiles and pass them off to say, logtool, to make
	    reports to e-mail people, or create webpages, and other similar 
	    uses.

	Notes:

	This program _should_ compile/run on almost anything resembling UNIX,
although I have only tested with Linux.  Hopefully some of you will give it a
try on some of the other UNIX flavors out there.  It was written in plain old
C library function call's (no snprintf() or other things that are known to be 
pesky on some UNIX'es (Solaris anyone?)), and it compiles clean with -W -Wall 
-ansi -pedantic passed to the compiler, so I assume it is something like 
reasonable code (I'm a self-taught programmer, so all bets are off if the 
compiler lied :).

	Also, the documentation is not yet complete (nobody likes to write
documentation, me included), but what is there should be enough to get you
up to speed if you're at all familiar with UNIX or Linux.

	--A.L.Lambert <al@xjack.org>
