diff options
author | Rory Bradford <roryrjb@gmail.com> | 2022-06-05 14:13:50 +0100 |
---|---|---|
committer | Rory Bradford <roryrjb@gmail.com> | 2022-06-05 14:13:50 +0100 |
commit | e6e38c439b375b3f716b43ff2bd7094a96d17a0f (patch) | |
tree | 6170da04fbff5c4f1f72c5fc9060d11d84ecf02b | |
parent | 21b89ad57984a5caae0374fee3ee69dcdaf480e2 (diff) | |
download | rf-e6e38c439b375b3f716b43ff2bd7094a96d17a0f.tar.gz |
Replace __progname with hardcoded name, include version in usage.
Signed-off-by: Rory Bradford <roryrjb@gmail.com>
-rw-r--r-- | rf.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/rf.c b/rf.c index a8fe80e..3066720 100644 --- a/rf.c +++ b/rf.c @@ -22,8 +22,6 @@ #define IGNORE "ignore" #define RFIGNORE ".rfignore" -extern char *__progname; - struct ignores *global_ignores; struct ignores *local_ignores; @@ -42,8 +40,8 @@ static void usage(char *error) { fprintf(stderr, "Error: %s\n\n", error); } - fprintf( - stderr, "usage: %s [-d directory] [-lsvw] pattern ...\n", __progname); + fprintf(stderr, "rf version %s\n\n", VERSION); + fprintf(stderr, "usage: rf [-d directory] [-lsvw] pattern ...\n"); } static int is_child(char *dirname) { |