Don't replace the newline, add it at the end of the line.
–
KevinNov 23 '11 at 19:42

@Nils, this sed Idea is brilliant but I don't know enough 'sed' to make it work, it looks like I cant capture newlines in the regexpt the usual way (that I am used to), I guess I need to tell sed dont interpret the incoming stream line by line.
–
AliNov 23 '11 at 20:13

1

@Ali Indeed, sed acts line by line and you don't directly see the newlines. sed -e $'s/$/\a/' adds a $'\a' (bell character in ksh/bash/zsh syntax) at the end of each line.
–
GillesNov 23 '11 at 20:35

Thanks @Tim, screen , shows and alert (I guess I can make it ring the bell as well) ONLY ONCE. Not for every new event that happens (not for every new line that is available)
–
AliNov 23 '11 at 20:11

1

i added an example for mac that could read the file to you. you could change that to work for linux by installing the linux version of logtail, and using the beep command, instead of say.
–
Tim KennedyNov 23 '11 at 20:29

cool! That is creative, although in my case I am using the beep to be able to monitor a log file without looking at screen. And the actual beep may be better than a voice.
–
AliNov 23 '11 at 20:40

1

Can also use screen's exec command to do it as well. The example in the manpage is !:sed -n s/.*Error.*/\007/p which will send a bell each time "Error" is displayed in that window.
–
ArcegeNov 24 '11 at 2:57