mirror of
https://github.com/sharkdp/hexyl.git
synced 2026-10-26 20:16:34 +00:00
Add default value for character table
This commit is contained in:
1 parent
4e66357618
commit
c4f91959ef
1 file changed
+2
-1
+2
-1
@@ -217,6 +217,7 @@ fn run() -> Result<()> {
|
||||
.long("character-table")
|
||||
.value_name("FORMAT")
|
||||
.value_parser(["codepage-437", "ascii-only"])
|
||||
.default_value("ascii-only")
|
||||
.help(
|
||||
"The character table that should be used. 'ascii-only' \
|
||||
will show dots for non-ASCII characters, and 'codepage-437 \
|
||||
@@ -483,7 +484,7 @@ fn run() -> Result<()> {
|
||||
|
||||
let char_table = match matches
|
||||
.get_one::<String>("character-table")
|
||||
.unwrap_or(&String::from("ascii-only"))
|
||||
.unwrap()
|
||||
.as_ref()
|
||||
{
|
||||
"ascii-only" => CharTable::AsciiOnly,
|
||||
|
||||
Reference in new issue
Block a user