Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

Re: | less +F buffering problem?

by zentara (Archbishop)
on Aug 18, 2006 at 13:44 UTC ( [id://568146] : note . print w/replies, xml ) Need Help??

in reply to | less +F buffering problem?

Hi, I ran your script and it works fine with
echo "pdf" >> /tmp/my.log
pdf appears in the watchers output, within a few seconds.
echo "lala" >> /tmp/my.log
does nothing

I'm not really a human, but I play one on earth. Cogito ergo sum a bum

Replies are listed 'Best First'.
Re^2: | less +F buffering problem?
by axelrose (Scribe) on Aug 18, 2006 at 13:54 UTC
    That's presumably because you left out the command line parameter '-p .'. Then it checks per default for the string "pdf".

    If I just run the script without piping it to less all is fine here as well.

    It's just that somehow " -p . /tmp/my.log | less +F" remains empty and it's not general problem because this:

    perl -e 'print "a line\n" x 10' | less +F