Skip to content

Add interface translations (sgn-translations) - #62

Closed
Globgor wants to merge 4 commits into
solgenomics:masterfrom
Globgor:i18n/sgn-translations
Closed

Globgor wants to merge 4 commits into
solgenomics:masterfrom
Globgor:i18n/sgn-translations

Conversation

@Globgor

@Globgor Globgor commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

This PR adds the interface translations of sgn to the image:

  • the sgn-translations repository as a submodule at cxgn/sgn-translations;
  • the Debian packages gettext and libintl-perl;
  • RUN make -C /home/production/cxgn/sgn-translations, which builds the .mo files and browser message files into its build/ folder.

sgn reads them from ../sgn-translations/build only when i18n_enabled is set; with it off nothing changes. The sgn side comes in a separate PR (part of solgenomics/sgn#5915).

I checked the make step inside the current breedbase/breedbase image (2026-11-06): it builds Ukrainian, Spanish and Arabic (about 20 MB), and www-data, the user that runs SGN in this image, can read the result. I did not build the whole image locally.

Prepared with AI assistance (Claude Code).

Add the sgn-translations repository as a submodule at
cxgn/sgn-translations, install gettext and libintl-perl, and build the
translations with make during the image build. sgn reads the built
files from ../sgn-translations/build when i18n_enabled is set; with it
off nothing changes.

AI-Tool: Claude Code
make created build/ with mode 0700 (tempfile.mkdtemp), so SGN, which
runs as www-data in this image, could not read the translations built
as root. sgn-translations now gives build/ the mode of the umask.

AI-Tool: Claude Code
@Globgor

Globgor commented Nov 14, 2026

Copy link
Copy Markdown
Contributor Author

I am closing this PR in favour of a smaller one. The new PR only adds the Debian package libintl-perl. The translations submodule and its build step will come later as a separate PR, once sgn has strings to translate.

@Globgor Globgor closed this Nov 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant