]> git.ipfire.org Git - thirdparty/git.git/blobdiff - builtin/worktree.c
Merge branch 'jc/orphan-unborn' into maint-2.43
[thirdparty/git.git] / builtin / worktree.c
index 71e0552a541d79a2451fb93dae19c8f6b5d61173..cac83a94197dd60054d5266de8cc1b5186ea2b35 100644 (file)
@@ -730,11 +730,11 @@ static int dwim_orphan(const struct add_opts *opts, int opt_track, int remote)
        }
 
        if (opt_track) {
-               die(_("'%s' and '%s' cannot be used together"), "--orphan",
-                   "--track");
+               die(_("options '%s' and '%s' cannot be used together"),
+                   "--orphan", "--track");
        } else if (!opts->checkout) {
-               die(_("'%s' and '%s' cannot be used together"), "--orphan",
-                   "--no-checkout");
+               die(_("options '%s' and '%s' cannot be used together"),
+                   "--orphan", "--no-checkout");
        }
        return 1;
 }
@@ -806,16 +806,17 @@ static int add(int ac, const char **av, const char *prefix)
        if (!!opts.detach + !!new_branch + !!new_branch_force > 1)
                die(_("options '%s', '%s', and '%s' cannot be used together"), "-b", "-B", "--detach");
        if (opts.detach && opts.orphan)
-               die(_("options '%s', and '%s' cannot be used together"),
+               die(_("options '%s' and '%s' cannot be used together"),
                    "--orphan", "--detach");
        if (opts.orphan && opt_track)
-               die(_("'%s' and '%s' cannot be used together"), "--orphan", "--track");
+               die(_("options '%s' and '%s' cannot be used together"),
+                   "--orphan", "--track");
        if (opts.orphan && !opts.checkout)
-               die(_("'%s' and '%s' cannot be used together"), "--orphan",
-                   "--no-checkout");
+               die(_("options '%s' and '%s' cannot be used together"),
+                   "--orphan", "--no-checkout");
        if (opts.orphan && ac == 2)
-               die(_("'%s' and '%s' cannot be used together"), "--orphan",
-                   _("<commit-ish>"));
+               die(_("option '%s' and commit-ish cannot be used together"),
+                   "--orphan");
        if (lock_reason && !keep_locked)
                die(_("the option '%s' requires '%s'"), "--reason", "--lock");
        if (lock_reason)