[ntp:hackers] ntpq width output

Terje Mathisen terje at tmsw.no
Fri Aug 15 06:36:25 UTC 2014


Hal Murray wrote:
> terje at tmsw.no said:
>> -W would also be better for reading the output on a wide screen: 80-col
>> CRTs are just so 1980!
> I think that's tangling several issues.
>
> Yes, it would be nice if the printout of some variant of ntpq -p would take
> advantage of modern wide screens.  On the other hand, we are stuck with mail
> systems that have a serious line length restriction.
>
> The original proposal (new line after long chunks) works with email.  My
> proposal (no newline) works with parsers but would be hard to read because
> the columns wouldn't line up.  There is a 3rd case which would be to just
> make the columns wider.
>
> The current output of ntpq -p is already too wide for most mail systems.
> Maybe we need a narrow version that does fit?  Or two versions, depending
> upon what gets left out.
>
I can see the need for mailable output, since that is what we can ask 
people to post when the are in trouble.

However, it would seem to me that this should rather be a less compact 
format, maybe even xml or (better imho) json?

These formats are newline-independent, and for most ntpq type outputs 
json would still fit in a screenful or two, while allowing very easy 
computer parsing.

Terje


-- 
- <Terje at tmsw.no>
"almost all programming can be viewed as an exercise in caching"



More information about the hackers mailing list