]> git.ayabusa.dev Git - thoryum.git/commitdiff
updated cli flags
authorAyabusa <lebgpub@gmail.com>
Thu, 11 Jun 2026 17:22:04 +0000 (19:22 +0200)
committerAyabusa <lebgpub@gmail.com>
Thu, 11 Jun 2026 17:22:04 +0000 (19:22 +0200)
src/cli.c

index beeac75b925b1531f8f20210e85491ef38b1d092..fdaf60d681d9c2305135455fc37d9188922fff5e 100644 (file)
--- a/src/cli.c
+++ b/src/cli.c
@@ -21,19 +21,19 @@ struct ctx *init_ctx(int argc, char **argv) {
     struct ctx *ctx = calloc(1, sizeof(struct ctx));
     int opt;
 
-    while ((opt = getopt(argc, argv, "yul:")) != -1) {
+    while ((opt = getopt(argc, argv, "ycl:")) != -1) {
         switch (opt) {
         case 'y':
             ctx->silent = 1;
             break;
-        case 'u':
+        case 'c':
             ctx->mode = UPDATE;
             break;
         case 'l':
             ctx->install_loc = strdup(optarg);
             break;
         default: // bozo
-            fprintf(stderr, "Usage: %s [-h] [-u] [-y] [-l path]\n",
+            fprintf(stderr, "Usage: %s [-h] [-c] [-y] [-l path]\n",
                     argv[0]);
             free(ctx);
             exit(EXIT_FAILURE);
@@ -80,7 +80,7 @@ void print_help() {
     "  -y\n"
     "      Do not ask for confirmation and apply the install directly.\n"
     "\n"
-    "  -u [DO NOT USE !!!]\n"
+    "  -c [DO NOT USE !!!]\n"
     "      This is used internally to check updates for an existing install,\n"
     "      it should not be invoked by the user.\n"
     "\n"