diff options
author | Thomas Voss <mail@thomasvoss.com> | 2022-11-04 20:11:34 +0100 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2022-11-04 20:11:34 +0100 |
commit | ef5fcf36e9a852669c6db43352cac5d841ae210d (patch) | |
tree | 9145acceddec94ea8c6afc555f1f8a958da45565 | |
parent | 0a25a86c098a2a06d8f6948bdb074e2bc0dcaf4e (diff) |
Move the flags in the usage string to PROG_ARGS
This allows us to wrap the code to 80 columns while still remaining
rather readable.
-rw-r--r-- | center.c | 7 |
1 files changed, 2 insertions, 5 deletions
@@ -29,6 +29,7 @@ #include <unistd.h> #define ESC 033 +#define PROG_ARGS "[-elr] [-t width] [-w width] [file ...]\n" #define die(...) err(EXIT_FAILURE, __VA_ARGS__) #define diex(...) errx(EXIT_FAILURE, __VA_ARGS__) @@ -92,11 +93,7 @@ main(int argc, char **argv) width = polong(optarg, "output width"); break; default: - fprintf( - stderr, - "Usage: %s [-elr] [-t width] [-w width] [file ...]\n", - argv[0] - ); + fprintf(stderr, "Usage: %s " PROG_ARGS, argv[0]); exit(EXIT_FAILURE); } } |