[darcs-users] [patch37] Store textual patch metadata encoded in UTF-8

Juliusz Chroboczek Juliusz.Chroboczek at pps.jussieu.fr
Wed Nov 11 01:15:11 UTC 2009


> Here is the patch that makes darcs store patch name, author and log as UTF-8 encoded strings.

> The patches makes darcs differentiate between old-style and UTF-8 patches by
> adding an 'Ignore-this: UTF-8' line to the patch log, and looking for that
> line when interpreting the patch.

No.  There's no need to tag.

UTF-8 can be detected automatically with 100% certainty in practice.  If
a string correctly decodes as UTF-8, then it's most certainly UTF-8.

This way, a locale-specific string in a UTF-8 locale is identical to
a locale-independent patch.

> The patches make darcs treat old-style patches as locale-encoded. This may be
> controversial. I did this because I suppose that people have already been
> using darcs with non-ASCII locales, using its encoding ignorance as a feature.
> They may have recorded patches with metadata in UTF-8 or other multibyte
> encodings, and it would be sorry for them to start displaying such metadata
> interpreted as ASCII or latin-1.

Please autodetect UTF-8.

                                        Juliusz


More information about the darcs-users mailing list