argument parsing into structure

SealabJaster sealabjaster at gmail.com
Wed Jun 26 17:30:54 UTC 2019


On Wednesday, 26 June 2019 at 14:58:08 UTC, Basile B. wrote:
> I think we are several having written alternative getopt() 
> systems.
> ...

Here's another one to add to the list: 
https://code.dlang.org/packages/jcli

Similar to you I'm pretty sure there's glaring issues I haven't 
seen/fixed yet.

Since it'll be *a while* until I get documentation written, 
features written, and bugs fixed, the points of interests (or 
detest :) ) over other libraries would be:

* I'm trying to make all the building blocks reusable, so even if 
the user doesn't like my particular style, they'll still have the 
tools to easily make their own version.

* Building blocks include: A dodgy pull parser for arguments; A 
builder class for help text, currently with two built-in content 
providers (which means the user can also make their own); An 
ArgBinder helper, which can be used to create user-defined 
argument binder without any boilerplate outside of simply making 
the binder; And while there's only a few right now, I'm wanting 
to add a bunch of utility functions similar to scriptlike.

The ArgBinder is probably the only fully interesting part tbh 
(more for how it's used, rather than how it's implemented), full 
documentation is in it's doc comment (binder.d).


More information about the Digitalmars-d-announce mailing list