From a1661a41226792ed971674081ca2b423450c1fb8 Mon Sep 17 00:00:00 2001 From: GRMrGecko Date: Thu, 1 Aug 2024 02:16:23 -0500 Subject: [PATCH] Add help output --- README.md | 44 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/README.md b/README.md index af7ce28..9620eaf 100644 --- a/README.md +++ b/README.md @@ -134,3 +134,47 @@ http { } } ``` + +## Help +``` +$ ./nginx-cache-purge --help +Usage: nginx-cache-purge [flags] + +Tool to help purge cache from Nginx + +Flags: + -h, --help Show context-sensitive help. + --version Print version information and quit + +Commands: + server (s) Run the server + purge (p) Purge cache now + +Run "nginx-cache-purge --help" for more information on a command. + +$ ./nginx-cache-purge p --help +Usage: nginx-cache-purge purge (p) [flags] + +Purge cache now + +Arguments: + Path to cache directory. + Cache key or wildcard match. + +Flags: + -h, --help Show context-sensitive help. + --version Print version information and quit + + --exclude-key=EXCLUDE-KEY,... Key to exclude, can be wild card and can add multiple excludes. + +$ ./nginx-cache-purge s --help +Usage: nginx-cache-purge server (s) [flags] + +Run the server + +Flags: + -h, --help Show context-sensitive help. + --version Print version information and quit + + --socket=STRING Socket path for HTTP communication. +``