Closed kbknapp closed 8 years ago
Whatyaknow, it exposed a bug. Once I get this fixed I'll re-open :stuck_out_tongue_winking_eye:
Turned out it wasn't a bug per-se. The issue was -dboolinator
since it's declared as multiple(true)
it was trying to parse the script as another value to -d
.
The fix is simple, I added number_of_values(1)
which says, -dval1 -dval2 -dval3
is valid but -dval1 val2 val3
isn't. I.e. now there's a distinction between multiple values, and multiple occurrences of an arg, and sometimes those two terms overlap a bit.
This commit updates
clap
to v2.4.0 which contains a bunch of bug fixes and improvements. This PR also includes buildingclap
with all default features as the oldcolor
feature is no longer built on Windows systems and therefore no longer an issue.Besides the bump in version of
clap
, and associated simple name changes (of which only 3 affected this crate) such asadd_all
->args
(etc.), theowned_vec_string
function has been changed slightly to reflectclap
s returning anIterator<Item=&str>
instead of aVec<&str>
.I was updating
cargo-extras
and since I'm not sure how to allow different[bin]
tables to accept different major versions of a particular crate (clap
in this case), this was one of the subcommands that needed an update to buildcargo-extras
.The
color
feature shouldn't have a negative affect anymore since there are nowcfg
flags in place to ensure it doesn't do anything in Windows. But you may want to double check this real quick since I'm not typically a windows dev.