More advanced flag help support
While looking at how other programs handle flags I found some special cases:
--[no-]xxxx, which is a pair of flags to override a boolean value, with one help and different resulting values. listing them both would also be ok (--xxxx,--no-xxxx) So this is a request of having one help for multiple options.-Wxxx, which is often used to enable warnings in compilers,-Was ashortflag is trivial, but we want to have multiple help pages per option with expanded valid values.
So I would like help pages not having to be in a 1:1 relation with options.
This duplicates https://github.com/pcapriotti/optparse-applicative/issues/243 and https://github.com/pcapriotti/optparse-applicative/issues/148.
I should put up a wiki page on some of these.
Not quite, my request is about decoupeling help pages from options.
We already can implement --no-xxx and --xxx but either one has no help, we group them in a bigger block, have a short help in --no-xxx: "Disable xxx, see --xxx". I would want the ability to have one help page for multiple options. Even though #148 is nice to have, this would be an orthogonal feature though nice to have together. Another example of the usefulness, is with flags, which have been renamed in the past so we list both under the same help.
The 2. is also not a duplicate of #243. It's about a shortflag with a required parameter. Though since there is a lot of behaviour in determined based on the value, we want to have a help for each value. For example:
--warning=all
Enables all warnings, this includes ...
--warning=unused-variables
Warn when variables are declared without being used
instead of
--warning=WARNING
all
Enables all warnings, this includes ...
unused-variables
Warn when variables are declared without being used