-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
i18n: Add compatibility for Transifex (industry standard provider for open source translations) #5341
Comments
"Transifex is a proprietary, web-based translation platform;" https://en.wikipedia.org/wiki/Transifex I see very little "open source" in that project/product? |
It's the leading provider of free translations for major open source projects. |
Name a few. |
I named one major one, I know many other major OS projects using it, will list them in a bit :) |
Here's a comprehensive list (43 million references to Transifex in GitHub code :D ): https://github.com/search?q=transifex&type=Code |
OK, thanks. I have thought about this in the past -- and here is my thought about how we could add support for other formats:
A nice addition to the above (but harder to implement) is a converter the other way. |
The v2 beta of go-i18n has just been released and supports a new flatter YAML language file format which at first glance appears to offer compatibility with translation providers like Transifex - see nicksnyder/go-i18n#85 Perhaps we could consider just moving to this significantly more popular format which is now supported by go-i18n. My other recent proposal (#5342) would help prevent breaking user's sites. |
This issue has been automatically marked as stale because it has not had recent activity. The resources of the Hugo team are limited, and so we are asking for your help. |
Ideally, Hugo would just use one of the plethora of existing, standard, full-featured formats that are supported by lots of translation platforms. For example, Weblate is actually free software and many software packages are translated on it. Here are the formats it supports: https://docs.weblate.org/en/latest/formats.html Using something like Chrome/WebExtensions JSON seems like a good bet: |
Mozilla is switching Firefox and many other of its projects to its Fluent 1.0 format, which extends on what gettext and XLIFF offer. They already have parsers in Javascript, Python, and Rust, so writing a Go parser shouldn't be too hard. They are pushing this format for websites also, so it could make sense for Hugo also. I haven't used it myself though. |
Problem
Popular themes for Hugo, such as Academic, offer language packs to enable users to easily change the interface language to their native language.
Currently, the format used for Hugo's YAML language packs is incompatible with leading open source translation providers, such as Transifex.
Thus, Hugo language packs are currently very difficult to manage (Academic has over 18 languages), difficult to keep in sync with the master language file, and without the ability to perform translations via the key open source translation providers.
Proposal
Restructure the YAML language file into a standardized format in order to align it with the standardized form used by other major open source projects (e.g. django-rest-framework).
This would make Hugo and its themes compatible with existing language pack translation management tool such as Transifex, the industry standard provider of language translations for open source projects.
The text was updated successfully, but these errors were encountered: