From bb300293cca12f9a6c41f349c02e71456666725e Mon Sep 17 00:00:00 2001 From: Martin Lund Date: Thu, 10 Feb 2022 15:07:14 +0100 Subject: [PATCH] Rename option -i to -L --- README.md | 2 +- man/tio.1.in | 2 +- src/options.c | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index ecdce0c..55ef14f 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ The command-line interface is straightforward as reflected in the output from -n, --no-autoconnect Disable automatic connect -e, --local-echo Do local echo -t, --timestamp Timestamp lines - -i, --list-devices List available serial devices + -L, --list-devices List available serial devices -l, --log Log to file -m, --map Map special characters -v, --version Display version diff --git a/man/tio.1.in b/man/tio.1.in index 3bb5282..947f69f 100644 --- a/man/tio.1.in +++ b/man/tio.1.in @@ -62,7 +62,7 @@ Enable local echo. Timestamp lines. .TP -.BR \-i ", " \-\-list\-devices +.BR \-L ", " \-\-list\-devices List available serial devices. diff --git a/src/options.c b/src/options.c index 1e5d39e..8fd3966 100644 --- a/src/options.c +++ b/src/options.c @@ -66,7 +66,7 @@ void print_help(char *argv[]) printf(" -n, --no-autoconnect Disable automatic connect\n"); printf(" -e, --local-echo Do local echo\n"); printf(" -t, --timestamp Timestamp lines\n"); - printf(" -i, --list-devices List available serial devices\n"); + printf(" -L, --list-devices List available serial devices\n"); printf(" -l, --log Log to file\n"); printf(" -m, --map Map special characters\n"); printf(" -v, --version Display version\n"); @@ -117,7 +117,7 @@ void parse_options(int argc, char *argv[]) {"no-autoconnect", no_argument, 0, 'n'}, {"local-echo", no_argument, 0, 'e'}, {"timestamp", no_argument, 0, 't'}, - {"list-devices", no_argument, 0, 'i'}, + {"list-devices", no_argument, 0, 'L'}, {"log", required_argument, 0, 'l'}, {"map", required_argument, 0, 'm'}, {"version", no_argument, 0, 'v'}, @@ -129,7 +129,7 @@ void parse_options(int argc, char *argv[]) int option_index = 0; /* Parse argument using getopt_long */ - c = getopt_long(argc, argv, "b:d:f:s:p:o:netil:m:vh", long_options, &option_index); + c = getopt_long(argc, argv, "b:d:f:s:p:o:netLl:m:vh", long_options, &option_index); /* Detect the end of the options */ if (c == -1) @@ -183,7 +183,7 @@ void parse_options(int argc, char *argv[]) option.timestamp = true; break; - case 'i': + case 'L': option.list_devices = true; break;