Get started localization with Lokalise.co
(FOLIO-1143)
|
|
| Status: | Closed |
| Project: | FOLIO |
| Components: | None |
| Affects versions: | None |
| Fix versions: | None | Parent: | Get started localization with Lokalise.co |
| Type: | Sub-task | Priority: | P3 |
| Reporter: | Peter Murray | Assignee: | Peter Murray |
| Resolution: | Done | Votes: | 0 |
| Labels: | sprint45 | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original estimate: | Not Specified | ||
| Attachments: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Issue links: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Sprint: | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Description |
|
This is the other end of the GitHub integration (
|
| Comments |
| Comment by Peter Murray [ 20/Jun/18 ] |
|
Having problems getting this to work in Lokalise, and have contacted their support desk: Conversation with Nick, CEO, 7:46 pm in Riga, Latvia
|
| Comment by Cate Boerema (Inactive) [ 26/Jun/18 ] |
|
Hi Peter Murray! The Translation Management Tool was slated for the Q2 release and, as I understand it from István Bender, this is the only remaining work needed to consider that complete. Any chance we can get this done this week so we can call it done? |
| Comment by Peter Murray [ 26/Jun/18 ] |
|
Hi Cate Boerema. This turns out not to be as straight forward as initially thought. Lokalise asked us to put in a feature request for the ability to filter language files into specific GitHub repositories. In the meantime, István Bender suggested manually committing language file changes to the GitHub repositories. I will aim to get a script done this week that will do that. |
| Comment by Peter Murray [ 26/Jun/18 ] |
|
On Jun 26, 2018, 2:06 AM -0500, Andrew from Lokalise <andrew@lokalise.co>, wrote:
I created a feature request to have Lokalise do what we want. |
| Comment by István Bender [ 27/Jun/18 ] |
|
Thanks Peter! I voted to the feature request and asked the colleagues to vote as well |
| Comment by István Bender [ 27/Jun/18 ] |
|
Peter Murray Meantime Hungarian translation is 100% ready! It can be a test language for your script! |
| Comment by István Bender [ 10/Jul/18 ] |
|
Peter Murray How are you going on with the script? |
| Comment by Peter Murray [ 14/Jul/18 ] |
|
It is coming along. The Lokalise API description isn't as nice as I was hoping for, but I got data out of it now that replicates what I get from the web UI options. Finishing up the GitHub pieces now. |
| Comment by Peter Murray [ 16/Jul/18 ] |
|
I have set up a script to work around the automatic Lokalise-pull-creation problem. The script is running with hard-coded config values, and it generates pull requests that look like this: https://github.com/folio-org/stripes-components/pull/493 Open questions:
I'm leaning towards the first option because:
Automated code merge processes make me nervous, but in this case – with this limited scope – I think it is okay. Thoughts? |
| Comment by Julian Ladisch [ 17/Jul/18 ] |
|
Automatic merge is ok with me. How does the script check that all translators have signed the Contributor License Agreement? |
| Comment by Peter Murray [ 17/Jul/18 ] |
It doesn't, and that is a good point. The user account system on Lokalise is distinct from GitHub. The commits for all translated strings come from the 'folio-translations' account no matter who put them into Lokalise. Based on the inquiries I've seen so far, it is likely that we will have a bunch of people offering translations that don't have GitHub accounts. We will need to devise a mechanism to ensure they agree to the CLA terms without having to go through the CLA Assistant tied to a GitHub account.
This isn't possible through the API call I'm using now to export all strings. It looks like the user who contributed the string isn't available through the list-pairs-by-language API call either. I'll need to ask the Lokalise support contact if it is possible to get a list of contributors. |
| Comment by Peter Murray [ 17/Jul/18 ] |
|
Query to Lokalise support:
Reply:
So I'll figure out a way to have translators acknowledge the CLA and wait for the API 2.0 to see if I can build a CONTRIBUTORS.txt file. |
| Comment by Peter Murray [ 21/Aug/18 ] |
|
Recalling the last conversation with John Coburn. There are a number of situations where a key is appearing in more than one file (for example, `button.edit` is in both `stripes-components` and `stripes-core`). Lokalise deduplicates keys coming from multiple files, so `button.edit` will be exported in only one git repository's translations directory (`stripes-core` in this case because it is the one that is last imported into Lokalise). The impact of this is unknown, so I'm going to modify the Lokalise-to-GitHub script to not replace `en.json` files (since the English files seem to be the most comprehensive). Then will run the script against all GitHub repositories to perform a single round trip from GitHub to Lokalise to GitHub. |
| Comment by Peter Murray [ 21/Aug/18 ] |
|
Translation files update with these pull requests:
All were merged with the exception of folio-org/ui-organization, which had a jenkins/pr-merge failure. |
| Comment by István Bender [ 22/Aug/18 ] |
|
We moved language files to translation/<modulename> folder in order to differetiate key collisions by file path. That's why we turned on "Include full path in the filenames" at the repository settings. Furthermore there is a setting at the pull option called "Differentiate keys by file". Perhaps we should turn it on as well to avoid deduplication. |
| Comment by Peter Murray [ 23/Aug/18 ] |
|
Yes, that did the trick István Bender. Translation files updated with these pull requests:
Going to see how folio-snapshot looks overnight, then enable the automatic merging of pull requests coming from Lokalise. |
| Comment by Peter Murray [ 31/Aug/18 ] |
|
Filed
|
| Comment by Peter Murray [ 01/Sep/18 ] |
|
Lokalise-to-GitHub run ran successfully to completion with all repositories but `ui-eholdings`. |
| Comment by Peter Murray [ 24/Sep/18 ] |
|
|