6 mars 2018 kl. 23.09 skrev Julian Foad <julianf...@apache.org>: > > The attached patch "split-long-strings-1.patch" (unfinished; see included log > message) puts code in place to achieve this for 'svn' help, and demonstrates > by splitting the 'svn log' and 'svn merge' strings.
In print_command_info3: + for (i = 0; cmd->help3[i] && i < SVN_OPT_MAX_PARAGRAPHS; i++) Check the index before using it, not after. > One issue occurs to me. If we make this change, splitting all the long > strings into paragraphs, won't that cause one enormous headache to the > translators because they will then have a bunch of paragraph-length strings > that the translation tools think are untranslated individually, even though > translations of them existed as substrings of a previous long string? Probably, but it's a one-time cost. The old translations will still be in the file as obsolete strings, for reference. And chances are that those strings are currently fuzzy anyway, if the translations haven't been updated for some time. > How could we ease that transition? It looks like it could be quite easy to > write a script that updates the .po files, if we choose our new breaks to be > at a deterministic points (e.g. every empty line), and if the current > translations keep the same structure (1:1 paragraphs) as the English version. > Would that work with most translators' work flows? Maybe, but it sounds brittle and error-prone, and we may not necessarily want to break at every empty line (the "merge" help, for example, contains lots of ASCII art that may or may not belong with a paragraph of prose). Since we don't know what parts are up to date, we would have to be pessimists and mark them all as fuzzy.