From 108f9f31881607364b9d8a0656b8ab9ab9706d5a Mon Sep 17 00:00:00 2001 From: Andrew Belt Date: Wed, 4 Jan 2023 05:25:50 -0500 Subject: [PATCH] Add --help command-line flag. --- adapters/standalone.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/adapters/standalone.cpp b/adapters/standalone.cpp index 940d645f..0e24be00 100644 --- a/adapters/standalone.cpp +++ b/adapters/standalone.cpp @@ -82,6 +82,7 @@ int main(int argc, char* argv[]) { {"system", required_argument, NULL, 's'}, {"user", required_argument, NULL, 'u'}, {"version", no_argument, NULL, 'v'}, + {"help", no_argument, NULL, 256}, {NULL, 0, NULL, 0} }; int c; @@ -112,6 +113,11 @@ int main(int argc, char* argv[]) { std::fprintf(stderr, "%s\n", appInfo.c_str()); return 0; } + case 256: { // --help + std::fprintf(stderr, "%s\n", appInfo.c_str()); + std::fprintf(stderr, "https://vcvrack.com/manual/Installing#Command-line-usage\n"); + return 0; + } // Mac "app translocation" passes a nonsense -psn_... flag, so -p is reserved. case 'p': break; default: break;