summaryrefslogtreecommitdiff
path: root/revision.c
diff options
context:
space:
mode:
authorJean-Noël Avila <jn.avila@free.fr>2022-01-05 20:02:16 (GMT)
committerJunio C Hamano <gitster@pobox.com>2022-01-05 21:29:23 (GMT)
commit12909b6b8a4a51e9d2b46610be4f93c782949c80 (patch)
treee0643769171bc1f80a17d52c7724b8fee3b21978 /revision.c
parentc488182903d97da70b7a486e514ab871345067cc (diff)
downloadgit-12909b6b8a4a51e9d2b46610be4f93c782949c80.zip
git-12909b6b8a4a51e9d2b46610be4f93c782949c80.tar.gz
git-12909b6b8a4a51e9d2b46610be4f93c782949c80.tar.bz2
i18n: turn "options are incompatible" into "cannot be used together"
Signed-off-by: Jean-Noël Avila <jn.avila@free.fr> Reviewed-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'revision.c')
-rw-r--r--revision.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/revision.c b/revision.c
index 5390a47..d28b63a 100644
--- a/revision.c
+++ b/revision.c
@@ -2300,11 +2300,11 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
revs->left_only = 1;
} else if (!strcmp(arg, "--right-only")) {
if (revs->left_only)
- die("--right-only is incompatible with --left-only");
+ die(_("options '%s' and '%s' cannot be used together"), "--right-only", "--left-only");
revs->right_only = 1;
} else if (!strcmp(arg, "--cherry")) {
if (revs->left_only)
- die("--cherry is incompatible with --left-only");
+ die(_("options '%s' and '%s' cannot be used together"), "--cherry", "--left-only");
revs->cherry_mark = 1;
revs->right_only = 1;
revs->max_parents = 1;
@@ -2313,12 +2313,12 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
revs->count = 1;
} else if (!strcmp(arg, "--cherry-mark")) {
if (revs->cherry_pick)
- die("--cherry-mark is incompatible with --cherry-pick");
+ die(_("options '%s' and '%s' cannot be used together"), "--cherry-mark", "--cherry-pick");
revs->cherry_mark = 1;
revs->limited = 1; /* needs limit_list() */
} else if (!strcmp(arg, "--cherry-pick")) {
if (revs->cherry_mark)
- die("--cherry-pick is incompatible with --cherry-mark");
+ die(_("options '%s' and '%s' cannot be used together"), "--cherry-pick", "--cherry-mark");
revs->cherry_pick = 1;
revs->limited = 1;
} else if (!strcmp(arg, "--objects")) {
@@ -2524,7 +2524,7 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
return opts;
}
if (revs->graph && revs->track_linear)
- die("--show-linear-break and --graph are incompatible");
+ die(_("options '%s' and '%s' cannot be used together"), "--show-linear-break", "--graph");
return 1;
}
@@ -2867,22 +2867,22 @@ int setup_revisions(int argc, const char **argv, struct rev_info *revs, struct s
compile_grep_patterns(&revs->grep_filter);
if (revs->reverse && revs->reflog_info)
- die("cannot combine --reverse with --walk-reflogs");
+ die(_("options '%s' and '%s' cannot be used together"), "--reverse", "--walk-reflogs");
if (revs->reflog_info && revs->limited)
die("cannot combine --walk-reflogs with history-limiting options");
if (revs->rewrite_parents && revs->children.name)
- die("cannot combine --parents and --children");
+ die(_("options '%s' and '%s' cannot be used together"), "--parents", "--children");
/*
* Limitations on the graph functionality
*/
if (revs->reverse && revs->graph)
- die("cannot combine --reverse with --graph");
+ die(_("options '%s' and '%s' cannot be used together"), "--reverse", "--graph");
if (revs->reflog_info && revs->graph)
- die("cannot combine --walk-reflogs with --graph");
+ die(_("options '%s' and '%s' cannot be used together"), "--walk-reflogs", "--graph");
if (revs->no_walk && revs->graph)
- die("cannot combine --no-walk with --graph");
+ die(_("options '%s' and '%s' cannot be used together"), "--no-walk", "--graph");
if (!revs->reflog_info && revs->grep_filter.use_reflog_filter)
die("cannot use --grep-reflog without --walk-reflogs");