[Linux-disciples] Color-coding script output
Adam Kessel
linux-disciples@bostoncoop.net
Thu, 28 Aug 2003 21:30:12 -0400
--9amGYk9869ThD9tj
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
How about perl module:
Term::ANSIColor - Color screen output using ANSI escape sequences
--Adam
On Wed, Aug 27, 2003 at 06:01:08PM -0400, Stephen R Laniel wrote:
> I have a little script that runs through my Apache logs and
> post-processes them in various ways (removing Nimda and Code Red hits,
> changing unresolved IP addresses into English names, etc.). The trouble
> is that reading the logs is still not quite as fast as I'd like it to be.
> I'd like the referrer to be color-coded one way, the hostname to be
> color-coded another, and so forth. So: do you know of any way to take a
> raw text file and pipe it through a Perl script, coming out with
> context-sensitive highlighting on the other end? The referrer, hostname,
> date and so forth are all quite easy to identify with a regex, so that's
> not the problem; I just want to know how to change the colors.
> Thoughts?
--9amGYk9869ThD9tj
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
iD8DBQE/TqykdTf3ZklQ6qYRAriUAKCWywK68EwBYYNr8v9hYGBEb6UClgCfXYR4
NYgWvn2+bBS9u+QdxqoQy3I=
=RB8s
-----END PGP SIGNATURE-----
--9amGYk9869ThD9tj--