Proposed argument changes to ntpq (fixing bug #319)

Eric S. Raymond esr at thyrsus.com
Thu Jun 8 19:01:55 UTC 2017


Gary E. Miller via devel <devel at ntpsec.org>:
> Yo Eric!
> 
> On Wed, 7 Jun 2017 22:46:42 -0400
> "Eric S. Raymond" <esr at thyrsus.com> wrote:
> 
> > Gary E. Miller via devel <devel at ntpsec.org>:
> > > 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 such a character is followed by a colon, the option requires an
> argu‐ ment, so getopt() places a pointer to the following text in the
> same argv-element, or the text of the following argv-element, in optarg.
> Two colons mean an option takes an optional arg;"

man getopt gets you the documentation of the *shell* getopt. Not useful here.

Mind you I didn't know it had this capability, so I learned something.
-- 
		<a href="http://www.catb.org/~esr/">Eric S. Raymond</a>

Please consider contributing to my Patreon page at https://www.patreon.com/esr
so I can keep the invisible wheels of the Internet turning. Give generously -
the civilization you save might be your own.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 811 bytes
Desc: not available
URL: <https://lists.ntpsec.org/pipermail/devel/attachments/20170608/2e3d5cc0/attachment.bin>


More information about the devel mailing list