On 8 October 2017 at 11:32, Philip Oakley <philipoakley@xxxxxxx> wrote: > From: "Martin Ågren" <martin.agren@xxxxxxxxx> > >> We currently build an error message like "entry is a %s, not a commit", >> where the placeholder will be replaced with "blob", "tag" or "tree". >> Apart from those three placeholder words not being translated, in some >> languages it might be awkward or impossible to ensure a grammatically >> correct end result. ... >> default: >> - die(_("submodule entry '%s' (%s) is a %s, not a commit"), >> - cb->path, oid_to_hex(oid), typename(type)); >> + die(_("submodule entry '%s' (%s) is not a commit"), >> + cb->path, oid_to_hex(oid)); > > Bikeshed, > maybe: > "submodule entry '%s' (%s) is not a commit. It is a %s" > This puts the two parts in separate sentences? I'm not doing the Swedish translation, but if I did, I would find this just as hard to translate as the original. There are two problems here. The first is "blob"/"tag"/"tree". "Blob" is already used in the Swedish translation, but "tag" should be "tagg" and "tree" should be "träd" (IMHO). The second problem is that even if all three words were valid Swedish words, then (IMHO) using "en %s" instead of "a %s" would be needed to make sense with "en blob" and "en tag", but it wouldn't work with "en tree" which should arguably be "ett tree". (But to be clear, seeing any of "en tree" and "ett tree" makes me shiver.) I should perhaps have been clearer that grammatical problems might arise from the "a". (It's more or less by chance that it works in English in the first place. Luckily there is no type "aardvark", "index" or "other".) But I wouldn't be surprised if there's a language out there where "a" is not a problem, but something else is. It just occurred to me that one approach would be something like "... is of type '%s', not 'commit'" where "commit" should not be translated and %s would be one of "blob", "tag" and "tree". That would be sort of in line with what `git cat-file` does, but not quite. In cat-file it seems natural because it's about the command-line argument, here it's in an error string and seems a bit awkward. Martin