Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Allow four character country code #255
So, by GNU Gettext it usually strictly
However, on practice it slightly different, because some locales can occur in few "variants". For instance, serbian
Pure GNU way to define same would be
I can't clearly understand what about this PR, but if it's is compatible with that slight deviation from ISO-only compatible locales, I'm
Just to highlight this once again, title of this PR says
Mar 29, 2017
1 check passed
referenced this pull request
Mar 29, 2017
Btw, finally figured completely is
Turns out, it is based on (relatively) new specs IETF BCP 47, which todays becomes de-facto standard and replaces old ISO 369-1, which was quite limited.
For instance, BCP 47 declares that locale can have following format:
As turns out, even HTML5 accepts language tag as a valid
A bit more info:
Unfortunately, seems that Gettext does not switch to that standard yet and continues to use ISO 639-1 for language and ISO 3166 for region only (so, in Gettext only locales like
But I really hope they switch to BCP 47, since it definately much better geared tower modern standards.
MS cultures seems to resemble BCP 47 standard, but I can't tell for sure — it differs from one MS document to another.