Dne 25.5.2011 09:45, Jim Warner napsal(a):
This changes situation. So problem isn't in line length but in variable columns length. That problem is even worse because you can have 400 spaces gap in middle of the output.On May 25, 2011, at 2:36 AM, Jan Görig wrote:Actually I send the e-mail because this. :-) It isn't problem to filter spaces in sed. But it is strange to have lines where are (for example) 80 bytes with information and 430 bytes with spaces...That only happens with one of those variable width columns as the last displayed field. Otherwise, there's just the single eol space.
Yes, I know behaviour of this option. But I think use case for '-b -w' options is to automatically process top informations and be sure that no column is truncated. The best solution is set variable length column size to length of its maximum string but I know this is difficult to determine. Maybe variable columns in wide batch mode should have only one trailing space. I know this breaks readability but it is probably best solution for batch purpose.I could address this specifically for Batch mode but it's been that way forever. What do you recommend? Incidentally, yesterday I failed to mention the best way to avoid line wraps in Batch mode. By leaving off the width switch, the terminal dimensions are in effect. ./top -b
Jan