I wrote a script which does (simplified):
tail -f logfile \
| grep --line-buffered "stuff" \
| sed -u "commands" \
| expand options \
| colrm cutoff
It works fine (that is, I get output when the logfile grows) as long as the
colrm isn't there. When I put it in, it stalls, apparently eating further
output until either colrm or expand decides to flush its buffer. How can I
tell it not to buffer more than one line at a time, as grep and sed have
been instructed? "expand" is well-behaved when the end of a pipeline though
that may change when its stdout isn't a TTY.
-- -eben QebWenE01R@vTerYizUonI.nOetP http://royalty.mine.nu:81"You're one of those condescending Unix computer users!" "Here's a nickel, kid. Get yourself a better computer" - Dilbert ----------------------------------------------------------------------- This list is provided as an unmoderated internet service by Networked Knowledge Systems (NKS). Views and opinions expressed in messages posted are those of the author and do not necessarily reflect the official policy or position of NKS or any of its employees.
This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 15:08:47 EDT