Skip to content
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

Add docs translation and the infrastructure and automation it requires #380

Merged
merged 4 commits into from
Sep 12, 2024

Conversation

CAM-Gerlach
Copy link
Member

Pull Request

Pull Request Checklist

  • Read and followed this repo's Contributing Guidelines
  • Based your PR on the latest version of the correct branch (master or 4.x)
  • Checked your writing carefully for correct English spelling, grammar, etc
  • Described your changes and the motivation for them below

Description of Changes

As a followup to #377 and #379 , add the actual infrastructure and automation tooling for translating the Spyder documentation, and the translations themselves.

Specifically, this adds:

  • The actual pot and po files with the translations, pulled from the versions in Crowdin
  • Commands for generating and updating the translation files
  • Commands for building the docs with multiple translations
  • CI support for the same
  • Crowdin configuration for future automatated pulls and pushes of translation updates

The site is now built into the translated versions; to view this, add LANGCODE/ to the URL after the version, currently either en/ or es/. There is not yet a GUI switcher for translations; the current translations can be switched by manually editing the URL. Additionally, the translations need some additional work to translate untranslated texts (overview, FAQ titles, captions, etc) and update the translation to be generated with the current documentation rather than one several months old. Therefore, it will remain beta for now.

@CAM-Gerlach CAM-Gerlach force-pushed the add-translation-infra branch 4 times, most recently from b57c412 to dd8985e Compare September 12, 2024 04:44
@CAM-Gerlach
Copy link
Member Author

Now updated the PR by:

  • Making the build-multilanguage command build both the base docs and the en and es locales (to fix the missing docs in the site root)
  • Adding a new build-languages command to build just the (specified or default) language(s) (previous behavior of build-multilanguage)
  • Modifying the update-po command to just update the en po by default (as we need with Crowdin, and for the forthcoming auto-update job)
  • Adding an --all-languages flag to restore the previous behavior of building all source and target languages, which now also supports specifying additional languages,
  • Adding a build-pot-po file to build new pot files, update the existing stored ones and also the en po-files from them, to allow updating the source translations in one command and to be used for the forthcoming auto-update job

Copy link
Member

@ccordoba12 ccordoba12 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work @CAM-Gerlach!

The final step to publish our Spanish translation is getting closer and closer!

@ccordoba12 ccordoba12 merged commit 7986519 into spyder-ide:master Sep 12, 2024
4 checks passed
@CAM-Gerlach
Copy link
Member Author

In fact, it's already technically published with this PR; we're just missing up to date/complete translations (which I can kick off shortly), and an easy way for people to switch between translations (the switcher).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants