i18n: refactor "unrecognized %(foo) argument" strings
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>
This commit is contained in:
parent
986cd6556c
commit
68e2ea0b30
14
ref-filter.c
14
ref-filter.c
@ -341,7 +341,7 @@ static int objectsize_atom_parser(struct ref_format *format, struct used_atom *a
|
|||||||
else
|
else
|
||||||
oi.info.disk_sizep = &oi.disk_size;
|
oi.info.disk_sizep = &oi.disk_size;
|
||||||
} else
|
} else
|
||||||
return strbuf_addf_ret(err, -1, _("unrecognized %%(objectsize) argument: %s"), arg);
|
return strbuf_addf_ret(err, -1, _("unrecognized %%(%s) argument: %s"), "objectsize", arg);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -374,7 +374,7 @@ static int subject_atom_parser(struct ref_format *format, struct used_atom *atom
|
|||||||
else if (!strcmp(arg, "sanitize"))
|
else if (!strcmp(arg, "sanitize"))
|
||||||
atom->u.contents.option = C_SUB_SANITIZE;
|
atom->u.contents.option = C_SUB_SANITIZE;
|
||||||
else
|
else
|
||||||
return strbuf_addf_ret(err, -1, _("unrecognized %%(subject) argument: %s"), arg);
|
return strbuf_addf_ret(err, -1, _("unrecognized %%(%s) argument: %s"), "subject", arg);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -428,7 +428,7 @@ static int contents_atom_parser(struct ref_format *format, struct used_atom *ato
|
|||||||
if (strtoul_ui(arg, 10, &atom->u.contents.nlines))
|
if (strtoul_ui(arg, 10, &atom->u.contents.nlines))
|
||||||
return strbuf_addf_ret(err, -1, _("positive value expected contents:lines=%s"), arg);
|
return strbuf_addf_ret(err, -1, _("positive value expected contents:lines=%s"), arg);
|
||||||
} else
|
} else
|
||||||
return strbuf_addf_ret(err, -1, _("unrecognized %%(contents) argument: %s"), arg);
|
return strbuf_addf_ret(err, -1, _("unrecognized %%(%s) argument: %s"), "contents", arg);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -440,7 +440,7 @@ static int raw_atom_parser(struct ref_format *format, struct used_atom *atom,
|
|||||||
else if (!strcmp(arg, "size"))
|
else if (!strcmp(arg, "size"))
|
||||||
atom->u.raw_data.option = RAW_LENGTH;
|
atom->u.raw_data.option = RAW_LENGTH;
|
||||||
else
|
else
|
||||||
return strbuf_addf_ret(err, -1, _("unrecognized %%(raw) argument: %s"), arg);
|
return strbuf_addf_ret(err, -1, _("unrecognized %%(%s) argument: %s"), "raw", arg);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -459,7 +459,7 @@ static int oid_atom_parser(struct ref_format *format, struct used_atom *atom,
|
|||||||
if (atom->u.oid.length < MINIMUM_ABBREV)
|
if (atom->u.oid.length < MINIMUM_ABBREV)
|
||||||
atom->u.oid.length = MINIMUM_ABBREV;
|
atom->u.oid.length = MINIMUM_ABBREV;
|
||||||
} else
|
} else
|
||||||
return strbuf_addf_ret(err, -1, _("unrecognized argument '%s' in %%(%s)"), arg, atom->name);
|
return strbuf_addf_ret(err, -1, _("unrecognized %%(%s) argument: %s"), atom->name, arg);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -531,7 +531,7 @@ static int align_atom_parser(struct ref_format *format, struct used_atom *atom,
|
|||||||
else if ((position = parse_align_position(s)) >= 0)
|
else if ((position = parse_align_position(s)) >= 0)
|
||||||
align->position = position;
|
align->position = position;
|
||||||
else {
|
else {
|
||||||
strbuf_addf(err, _("unrecognized %%(align) argument: %s"), s);
|
strbuf_addf(err, _("unrecognized %%(%s) argument: %s"), "align", s);
|
||||||
string_list_clear(¶ms, 0);
|
string_list_clear(¶ms, 0);
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
@ -557,7 +557,7 @@ static int if_atom_parser(struct ref_format *format, struct used_atom *atom,
|
|||||||
} else if (skip_prefix(arg, "notequals=", &atom->u.if_then_else.str)) {
|
} else if (skip_prefix(arg, "notequals=", &atom->u.if_then_else.str)) {
|
||||||
atom->u.if_then_else.cmp_status = COMPARE_UNEQUAL;
|
atom->u.if_then_else.cmp_status = COMPARE_UNEQUAL;
|
||||||
} else
|
} else
|
||||||
return strbuf_addf_ret(err, -1, _("unrecognized %%(if) argument: %s"), arg);
|
return strbuf_addf_ret(err, -1, _("unrecognized %%(%s) argument: %s"), "if", arg);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user