Rename --hex to --hex-mode

This commit is contained in:
Martin Lund 2022-06-17 10:56:12 +02:00
parent a826bf4fcb
commit 1b2f445ed9
3 changed files with 5 additions and 5 deletions

View file

@ -123,7 +123,7 @@ If defining more than one flag, the flags must be comma separated.
.RE .RE
.TP .TP
.BR \-x ", " \-\-hex .BR \-x ", " \-\-hex\-mode
Enable hexadecimal mode. Enable hexadecimal mode.

View file

@ -27,7 +27,7 @@ _tio()
-L --list-devices \ -L --list-devices \
-c --color \ -c --color \
-S --socket \ -S --socket \
-x --hex \ -x --hex-mode \
-v --version \ -v --version \
-h --help" -h --help"
@ -102,7 +102,7 @@ _tio()
COMPREPLY=( $(compgen -W "unix: inet: inet6:" -- ${cur}) ) COMPREPLY=( $(compgen -W "unix: inet: inet6:" -- ${cur}) )
return 0 return 0
;; ;;
-x | --hex) -x | --hex-mode)
COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ) COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
return 0 return 0
;; ;;

View file

@ -88,7 +88,7 @@ void print_help(char *argv[])
printf(" -m, --map <flags> Map special characters\n"); printf(" -m, --map <flags> Map special characters\n");
printf(" -c, --color 0..255|none|list Colorize tio text (default: 15)\n"); printf(" -c, --color 0..255|none|list Colorize tio text (default: 15)\n");
printf(" -S, --socket <socket> Listen on socket\n"); printf(" -S, --socket <socket> Listen on socket\n");
printf(" -x, --hex Enable hexadecimal mode\n"); printf(" -x, --hex-mode Enable hexadecimal mode\n");
printf(" -v, --version Display version\n"); printf(" -v, --version Display version\n");
printf(" -h, --help Display help\n"); printf(" -h, --help Display help\n");
printf("\n"); printf("\n");
@ -199,7 +199,7 @@ void options_parse(int argc, char *argv[])
{"socket", required_argument, 0, 'S' }, {"socket", required_argument, 0, 'S' },
{"map", required_argument, 0, 'm' }, {"map", required_argument, 0, 'm' },
{"color", required_argument, 0, 'c' }, {"color", required_argument, 0, 'c' },
{"hex", no_argument, 0, 'x' }, {"hex-mode", no_argument, 0, 'x' },
{"version", no_argument, 0, 'v' }, {"version", no_argument, 0, 'v' },
{"help", no_argument, 0, 'h' }, {"help", no_argument, 0, 'h' },
{0, 0, 0, 0 } {0, 0, 0, 0 }