Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Eric S. Raymond via devel
Ian Bruene via devel : > > > On 06/08/2017 05:29 PM, Gary E. Miller via devel wrote: > >NTPsec does not use Python's getopt(). It uses argparse(). > > So the real alternatives here are: > > 1. Have the dual -l/-L flags > > 2. Convert ntpq from getopt to argparse Ian, I'm going to mutter that

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Gary E. Miller via devel
Yo Ian! On Thu, 8 Jun 2017 17:34:27 -0500 Ian Bruene via devel wrote: > On 06/08/2017 05:29 PM, Gary E. Miller via devel wrote: > > NTPsec does not use Python's getopt(). It uses argparse(). > > So the real alternatives here are: > > 1. Have the dual -l/-L flags Yuck. Non orthogonal to nt

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Ian Bruene via devel
On 06/08/2017 05:29 PM, Gary E. Miller via devel wrote: NTPsec does not use Python's getopt(). It uses argparse(). So the real alternatives here are: 1. Have the dual -l/-L flags 2. Convert ntpq from getopt to argparse -- In the end; what separates a Man, from a Slave? Money? Power? No. A

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Gary E. Miller via devel
Yo Ian! On Thu, 8 Jun 2017 15:29:19 -0500 Ian Bruene via devel wrote: > >> "A (':') shall be returned if getopt() detects a missing > >> argument and the first character of optstring was a (':')." > >> > >> So optional optarg can be valid POXIX. > > I didn't know that. Thanks. > > Unfort

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Ian Bruene via devel
On 06/08/2017 02:48 PM, Eric S. Raymond via devel wrote: Gary E. Miller via devel : Well, more to be learned, my getopt(3p) is not the same as what I see on unix.com. The online copy did not include the snippet I quoted. You can confirm on the POSIX site for getopt(3P): http://www.unix.com/

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Eric S. Raymond via devel
Gary E. Miller via devel : > Well, more to be learned, my getopt(3p) is not the same as what I see on > unix.com. The online copy did not include the snippet I quoted. You > can confirm on the POSIX site for getopt(3P): > > http://www.unix.com/man-page/posix/3p/getopt/ > > But they both had thi

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Gary E. Miller via devel
Yo Eric! On Thu, 8 Jun 2017 15:01:55 -0400 "Eric S. Raymond" wrote: > Gary E. Miller via devel : > > Yo Eric! > > > > On Wed, 7 Jun 2017 22:46:42 -0400 > > "Eric S. Raymond" wrote: > > > > > Gary E. Miller via devel : > > > > Just make the filename optional. So -l or -l filename > > >

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Eric S. Raymond via devel
Gary E. Miller via devel : > Yo Eric! > > On Wed, 7 Jun 2017 22:46:42 -0400 > "Eric S. Raymond" wrote: > > > Gary E. Miller via devel : > > > Just make the filename optional. So -l or -l filename > > > > Sadly, not practical with any varint of C or Python getopt. We'd have > > to roll our own

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Ian Bruene via devel
On 06/08/2017 03:22 AM, Hal Murray wrote: If you are looking at ntpq, it would be nice if there was a simple way to see the packets sent/received and not much else. A few of the packets have binary data. It may be as simple as only assoc IDs are in binary. Everything else is raw ascii so it

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Hal Murray via devel
If you are looking at ntpq, it would be nice if there was a simple way to see the packets sent/received and not much else. A few of the packets have binary data. It may be as simple as only assoc IDs are in binary. Everything else is raw ascii so it doesn't need any complicated parsing or re

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-08 Thread Gary E. Miller via devel
Yo Eric! On Wed, 7 Jun 2017 22:46:42 -0400 "Eric S. Raymond" wrote: > Gary E. Miller via devel : > > Just make the filename optional. So -l or -l filename > > Sadly, not practical with any varint of C or Python getopt. We'd have > to roll our own, and that way madnes lies. man geetopt: "If

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-07 Thread Eric S. Raymond via devel
Gary E. Miller via devel : > Just make the filename optional. So -l or -l filename Sadly, not practical with any varint of C or Python getopt. We'd have to roll our own, and that way madnes lies. -- http://www.catb.org/~esr/";>Eric S. Raymond Please consider contributing to my Pa

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-07 Thread Gary E. Miller via devel
Yo Ian! On Wed, 7 Jun 2017 19:02:49 -0500 Ian Bruene wrote: > ntp*q* Sorry, my mistake. I read 'ntpd'. But still try to keep the options the same as possible. RGDS GARY --- Gary E. Miller Rellim 109 NW Wilmington Ave.,

Re: Proposed argument changes to ntpq (fixing bug #319)

2017-06-07 Thread Gary E. Miller via devel
Yo Ian! On Wed, 7 Jun 2017 18:31:15 -0500 Ian Bruene via devel wrote: > Currently ntpq has -d and -D flags which function much like the ones > for ntpd. Except that the -d flag also sets ntpq to log to a file > instead of stderr because, um, reasons? Evolution is hard to understand, much less m

Proposed argument changes to ntpq (fixing bug #319)

2017-06-07 Thread Ian Bruene via devel
Currently ntpq has -d and -D flags which function much like the ones for ntpd. Except that the -d flag also sets ntpq to log to a file instead of stderr because, um, reasons? Proposed interface change: -d/-D remain, but *only* affect the debug level Add flag -l / --log-file (alt: -f, etc)