http://qs1969.pair.com?node_id=817040


in reply to Suffering with buffering - how to wake 'less'

Printing to a full pipe causes the print to block. less doesn't read from its input until it needs to. I don't see any option to change that behaviour.

Replies are listed 'Best First'.
Re^2: Suffering with buffering - how to wake 'less'
by benizi (Hermit) on Jan 12, 2010 at 21:44 UTC

    Nuts. I was hoping for something like +G or +F that wouldn't cause less to fully block.

    Falling back to the ol' dosomething >& file &; less file approach.

    Thanks as always ikegami.

      producer > file & less file ; rm file
      doesn't work since less isn't expecting the file to change.
      producer > file ; less file ; rm file
      works, but less will only start up once the producer has ended.

        Oops. I'd typo'ed. I meant 'tail -f' where I said 'less'.