Skip to content
This repository was archived by the owner on Nov 6, 2023. It is now read-only.

Share translations between Chrome & FF - #1351

Merged
semenko merged 3 commits into
EFForg:masterfrom
jsha:chrome-translations
Feb 1, 2016
Merged

Share translations between Chrome & FF#1351
semenko merged 3 commits into
EFForg:masterfrom
jsha:chrome-translations

Conversation

@jsha

@jsha jsha commented Apr 3, 2015

Copy link
Copy Markdown
Member

Most of the messages for i18n are the same between Chrome and Firefox. This automates turning the Firefox local files into Chrome ones at build time, so Chrome will always have the same translations FF does, and the benefit of the larger translation community.

This removes one message that was unique to Chrome ("What is this?"), replacing it with "About HTTPS Everywhere." It also copies four other unique-to-Chrome messages into the FF locale files, preserving the already-translated copies of those.

cc @semenko @cooperq @diracdeltas

@jsha

jsha commented Apr 4, 2015

Copy link
Copy Markdown
Member Author

Also, fair notice: I haven't actually tested these translations because I couldn't figure out how to set the interface language in Chromium. Help appreciated!

@semenko

semenko commented Apr 4, 2015

Copy link
Copy Markdown
Contributor

Cool -- will test more in a bit. IIRC you can change the language at chrome://settings/languages

@jsha

jsha commented Apr 4, 2015

Copy link
Copy Markdown
Member Author

Unfortunately chrome://settings/languages only changes my Accept-Language header, it doesn't seem to change the interface language. This is on Linux with Chromium and Chrome, both. Does it work differently for you?

@semenko

semenko commented Apr 4, 2015

Copy link
Copy Markdown
Contributor

Hm, good call. I got this to work exporting a LANGUAGE= variable on Linux. I also set a temporary user profile directory:

LANGUAGE=es ./google-chrome-unstable --user-data-dir=/tmp/profile-test-ES

The --lang flag suggested at https://developer.chrome.com/extensions/i18n didn't seem to work for me either.

@jsha

jsha commented Apr 4, 2015

Copy link
Copy Markdown
Member Author

Awesome, this worked, thanks! Here's a neat trick to make it easier:

LANGUAGE=es ./run-chromium.sh

Builds the extension and runs it in a temporary profile.

It seems to be missing the "Stable rules" / "Experimental rules" translations for ES at least. That sort of makes sense - they haven't been translated - but ideally it should have the English strings there rather than blank space. I'll take a look next week.

@jsha

jsha commented May 12, 2015

Copy link
Copy Markdown
Member Author

Fixes #1207

@cooperq

cooperq commented May 15, 2015

Copy link
Copy Markdown
Contributor

Can you resolve the conflicts in this PR?

Also incorporate the handful of unique-to-chromium messages into FF dtd, and
remove some obsolete messages.
@jsha
jsha force-pushed the chrome-translations branch from bb3c4a4 to 804b0f9 Compare February 1, 2016 04:00
@jsha

jsha commented Feb 1, 2016

Copy link
Copy Markdown
Member Author

Okay, brought this branch up-to-date with the latest code.

Note: The newly added strings (e.g. "Stable rules") will show up as blank in non-English languages at the moment. Once this change hits master, Transifex will pick up the new strings and add them to all locales. So, once we update the translations submodule, we'll at least have English strings for those. And, as volunteers translate them and we continue to update the translations submodule, they will become available in the relevant languages.

@semenko

semenko commented Feb 1, 2016

Copy link
Copy Markdown
Contributor

I'm seeing blanks for "Stable Rules" in Chrome. Looks like the HTML is prefixed with chrome_ e.g. chrome_stable_rules but messages.json provides stable_rules.

screen shot 2016-02-01 at 10 33 20 am

@jsha

jsha commented Feb 1, 2016

Copy link
Copy Markdown
Member Author

Fixed, thanks.

semenko added a commit that referenced this pull request Feb 1, 2016
Share translations between Chrome & FF
@semenko
semenko merged commit 7c18c36 into EFForg:master Feb 1, 2016
@semenko

semenko commented Feb 23, 2016

Copy link
Copy Markdown
Contributor

FYI, I think this broke the "Add new rule" button in chrome (because it wasn't prefixed by chrome_). I might fix in a bit.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants