Argument --block-size
does not accept units (or hex numbers), contrary to its helptext description.
#111
Labels
--block-size
does not accept units (or hex numbers), contrary to its helptext description.
#111
The
hexyl --help
description for the--block-size
argument goes as follows:However, when I attempt to run
hexyl "$(which hexyl)" -n 1block --block-size=4kB
, hexyl prints the following error:This is caused by the
block_size
argument being parsed as a positive i64 number, rather than as a data unit:hexyl/src/bin/hexyl.rs
Lines 133 to 142 in cc5b308
Side note: If this bug was fixed, how would hexyl handle
--block-size=1block
? Should it be multiplying it by the default value, or would it be more appropriate to treat as an error to avoid any confusion?Edit: It also doesn't accept hexadecimal numbers.
Note: I'm doing a class assignment regarding creating tests (from scratch) for an open-source command line program, and I chose hexyl for it. You might have a couple more of these on the way, depending on what the assignment brings to light :)
The text was updated successfully, but these errors were encountered: