diff options
author | Joseph Hunkeler <jhunkeler@gmail.com> | 2024-03-11 09:38:03 -0400 |
---|---|---|
committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2024-03-11 09:38:03 -0400 |
commit | 3260743bf51338ad73becd62f62f0da7d1b51e8d (patch) | |
tree | db8e4d3f0e4f97fa1b99c9c41e8273f734e368a8 | |
parent | b7785ede614064cce7d130542cd840a72231f2c1 (diff) | |
download | stasis-3260743bf51338ad73becd62f62f0da7d1b51e8d.tar.gz |
Print ARG next to short option output in usage statement
-rw-r--r-- | src/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -111,6 +111,9 @@ static void usage(char *progname) { if (long_options[x].val <= 'z') { strcat(opt_short, "-"); opt_short[1] = (char) long_options[x].val; + if (long_options[x].has_arg) { + strcat(opt_short, " ARG"); + } } else { strcat(opt_short, " "); } |