[fpc-pascal] CLI argument parsers
Michael Van Canneyt
michael at freepascal.org
Mon Jan 14 09:41:31 CET 2019
On Mon, 14 Jan 2019, Martok wrote:
> I was 100% expecting that sort of answer.
My invitation to suggest improvements, you mean ?
I meant it: you're welcome to suggest improvements.
If you implement something like argpars and it can be used as backend for
TCustomApplication, I'm willing to rework TCustomApplication to use it.
This way we keep backwards compatibility and offer the possibility to extend
I'm not blind to the shortcomings of TCustomApplication argument parsing.
It fully handles the unix '-a' '--aaa' scheme of doing things, but currently
does not handle options in command form
prog --globalopts command [--commandopts] args
So, if you can offer something to keep current functionality and allow this
as well: be my guest...
But e.g. the geptops way, which basically forces you to use a while loop is
really not acceptable, which is why the TCustomApplication interface is what
it is today.
More information about the fpc-pascal