Closed QuLogic closed 3 years ago
-B
, -x
, and -b
are currently exclusive.
Not sure if I can improve the error message easily - let me see/think on that:
the option handling is provided by the optparse-applicative
library which while not perfect is quite nice.
fbrnch parallel -B -h
I agree this could be confusing but basically this is equivalent to fbrnch parallel --help
.
Help doesn't take any given options into account.
I agree this could be confusing but basically this is equivalent to
fbrnch parallel --help
. Help doesn't take any given options into account.
Oh, sorry, I didn't mean to be calling that out specifically, just that -x
didn't mention exclusivity.
To clarify better (also I feel optparse-applicative could lay out options better)
... ([-b|--branch BRANCH]
| [-B|--all-branches] | [-x|--exclude-branch BRANCH])
is meant to imply that -b, -B, and -x are all exclusive.
I agree the error message could be clearer. I may take a look at an alternative option processing library at some point - it might be a weakness of the Applicative approach.
(Also just a early historical note: that originally fbrnch defaulted to -B
for all commands essentially, but I decided to make it an option to not be too surprising/big a change compared to fedpkg.)
but
or
This works though:
It's not noted that
-B
and-x
are exclusive, but the error message should probably be different.