On 18/06/2026 10:26, Alexander Shopov wrote:
Hi all,

I am Alexander Shopov and I am updating the Bulgarian translation of
coreutils.

While it is at 100% it needs some improvement.
https://translationproject.org/domain/coreutils.html

Latest coreutils versions started adding links to the output of '--help'
option which
is very cool indeed.
This resulted in some changes in the visual formatting and flow of the
output.
I am trying to rework the translation so they look better and I have the
following questions:

1. Is there some logic behind the chosen offsets in the English
translation? For example:
the short option should always start at column 3, the long version should
start at column 7,
the meaning should start on column 24, the text should wrap at column 80

   -c, --check          изчитане на контролните суми от ФАЙЛовете и проверка
--3---7----------------2-------------------...
--------------------------------8
                        4
   0

2. You are trying to reuse strings as much as logically possible amongst
the commands
so all should use the same offsets, right?

3. Is there some special logic for the weaving of the links in the output
that I should be aware of?
Where exactly in the source is this specified? Have you changed the gettext
`_` macro?
Should the options be on a separate line for the magic to work?

4. Many commands also have other tabular-like outputs. (for example - the
`[` expressions).
Is there some further logic there or not?


Kind regards:
al_shopov

The hyperlinks are not directly related to the alignment.
I.e. the hyperlinks are only for the english option names,
which are consistent and unchanged at your 3,7 offsets above.
Also consistent is the wrapping within 80 characters.

What did change at the same time as adding the hyperlinks
(since the translations needed to be adjusted anyway),
was the offset for the start of the description (24 above).
Traditionally that description was on the same line as the option,
however that is harder to manage generally as described at:
https://github.com/coreutils/coreutils/commit/cab15fc4e

So in summary for languages that have similar horizontal width
as english, I would follow the alignment of the english translation,
which usually has the description on a separate line,
starting at offset 10. For example see:

ruler ()
{
    yes $(seq 9 | tr -d '\n') |
    head -n $((${LINES:-12}-2)) -n50 |
    paste -s -d¹²³⁴⁵⁶⁷⁸⁹⁰ |
    cut -c-$COLUMNS
}

$ TERM= cksum --help | grep -A1 -- --check; ruler
  -c, --check
         read checksums from the FILEs and check them
123456789¹123456789²123456789³123456789⁴123456789⁵123456789⁶123456789⁷12

Now there are a few exceptions like `[ --help`
where a single line is best, but again following
the english alignment is best where possible.

thanks,
Padraig

Reply via email to