News for hackers. Stuff that matters.
Re:Stop using tail -f (mostly) by toddkaufmann on Monday March 30, 2015 @01:55PM (#9291267)
Use '/' (search) to enter a regexp to match a pattern on that line, and it will be highlighted.
Re:Stop using tail -f (mostly) by lgas on Monday March 30, 2015 @02:43PM (#9291625)
This has nothing to do with what is being discussed in this subthread.
Re:Stop using tail -f (mostly) by teraflop on Monday March 30, 2015 @02:50PM (#9291672)
Sure it does. If your log lines are distinct (e.g. they have timestamps or unique IDs) then you can use less's search highlighting to provide a visual marker for a specific line, similar to what you can do by manually inserting a bunch of blank lines on the console.

This trick doesn't work if your log file has a bunch of identical lines and you want to keep an eye on their rate, though.

Re:Stop using tail -f (mostly) by gojomo on Monday March 30, 2015 @03:33PM (#9291988)
Having to remember & type a timestamp has much more mental overhead (planning & memory) than "scan/scroll back to last block of vertical whitespace".

That's why suggestions of either named-marks or back-searches aren't considered equally-attractive alternatives to marking the scrollback with a batch of <return>s.

Re:Stop using tail -f (mostly) by shawabawa3 on Monday March 30, 2015 @03:17PM (#9291872)
imagine the scenario: "I want to see everything that happens in a single request"

Enter method:

  1. Press enter a bunch of times
  2. Reload browser
  3. Press enter a bunch of times and scroll up
Your method:

  1. Search for last line in output to highlight it?
  2. Reload page
  3. Try and figure out where stuff starts and ends with loads of visual noise
Re:Stop using tail -f (mostly) by teraflop on Monday March 30, 2015 @05:53PM (#9292870)
I won't argue that for this specific use case, tail isn't friendlier than less.

But the original poster posted a useful tip, and is now getting aggressive downvotes and comments like "This has nothing to do with what is being discussed in this subthread." I think that's unwarranted.

Re:Stop using tail -f (mostly) by MadcapJake on Monday March 30, 2015 @04:10PM (#9292234)
less method:

  1. ma
  2. Reload browser
  3. 'a
less method with two marks:

  1. ma
  2. Reload browser
  3. mb
  4. 'a
Re:Stop using tail -f (mostly) by ajanuary on Monday March 30, 2015 @04:45PM (#9292470)
Unfortunately mark doesn't seem to work while you're following.
Re:Stop using tail -f (mostly) by shangxiao on Monday March 30, 2015 @04:13PM (#9292254)
A bunch of blank lines is a lot more grokable than timestamps lost in a bunch of text.