Difference between revisions of "Improve Localization Process"

From GnuCash
Jump to: navigation, search
(Intro)
 
(Toolkits: 1. user)
 
(13 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
Purpose of this page is to collect ideas to improve the Localization process of the several GnuCash components.
 
Purpose of this page is to collect ideas to improve the Localization process of the several GnuCash components.
 +
 +
[[Category:Documentation Development]]
 +
[[Category:Translation]]
  
 
==Motivation==
 
==Motivation==
 
It is often heard by translators, it is so hard to get a recent pot file for the one or other Gnucash component. This is the right place to sketch and evaluate ideas to improve the process.
 
It is often heard by translators, it is so hard to get a recent pot file for the one or other Gnucash component. This is the right place to sketch and evaluate ideas to improve the process.
  
 +
== Web Based Translation Tools ==
 +
Several services for translation coordination exist:
 +
;FOSS:
 +
:;[https://translate.wordpress.org/ GlotPress]: a site using the [https://wordpress.org/ wordpress] plugin, PHP based
 +
:;[https://en.wikipedia.org/wiki/Pootle Pootle]: for localization of applications' GUIs using, uses [[#Toolkits|Translate Toolkit]]
 +
:;[https://en.wikipedia.org/wiki/Translatewiki.net translatewiki.net]: uses [https://www.mediawiki.org/wiki/Extension:Translate mediawiki Extension:Translate]
 +
:;[https://en.wikipedia.org/wiki/Weblate Weblate]: (suggested by Pedro (pt_PT)), uses [[#Toolkits|Translate Toolkit]]
 +
:;[http://zanata.org/about/ Zanata]: [https://translate.zanata.org/explore site] CLI, REST-API, java/js based
 +
;Proprietary:
 +
:;[https://en.wikipedia.org/wiki/Crowdin Crowdin]: [https://crowdin.com/page/integrations integrations], for FOSS free
 +
:;[https://poeditor.com POEditor]: free for FOSS
 +
:;[https://en.wikipedia.org/wiki/Transifex Transifex]: GSM, SaaS, for FOSS free
 +
<!-- google 'git & translation tools' seems to be a good starting point -->
 +
:and [https://en.wikipedia.org/wiki/Category:Software-localization_tools several more]
 +
;Checklist:
 +
:VCS integration? GitHub vs. GitLab should not be an issue
 +
:Are they free? (Both meanings)
 +
 +
==Toolkits==
 +
[https://en.wikipedia.org/wiki/Translate_Toolkit Translate Toolkit], partially used by [{{URL:AB}}rdm/projects/aqbanking/repository/revisions/master/entry/README aqbanking].
 +
 +
==Implementation Thoughts==
 +
We had some discussion.
 +
 +
===Weblate===
 +
From https://lists.gnucash.org/logs/2020/10/15.html#T15:09:05 - 19:38:30; https://lists.gnucash.org/logs/2020/10/16.html#T07:59:20 - 12:02:34
 +
 +
In theory you can run your own weblate instance or have a hosted project at weblate.org, which is is free for FOSS. [[User:Fell]] thinks the hosted form could attract new translators and has less administrative overhead.
 +
 +
;Server Relation: Ideally code as primary git server should push changes to weblate.org. Weblate.org again should create PRs on github, which we then merge after review.
 +
;Status: Implemented on 2020-12-15. For the current status see [[Weblate]].
 +
 +
====Remaining Ideas by Repos====
 +
Each repo push it's (almost all [Exception TP]) existing po files.
 +
;ToDo: They should contain their pot file to allow users to create translations for new languages.
 +
 +
;glossary: Got high priority, so it is listed first. Origin: gnucash:po/glossary
 +
:;ToDo:
 +
::# We should recommend to translate it first and after approval load it into Weblates glossary.
 +
::# Replace <tt>MsgId="*: </tt> by <tt>Msgcontext="*"\nMsgId="</tt>
 +
:;Update: If <tt>gnc-glossary.txt</tt> changes,
 +
::#run txt-to-pot.sh
 +
::#msgmerge it in all po files
 +
::#commit and push
 +
 +
;gnucash:
 +
:;Determinating string changes: Before committing changes to C, scm, … source files generate a gnucash.pot. Or we change the policy and add it to the repo.
 +
::# After the commit create a tmp.pot.
 +
::# Create a diff between both pot files filtered by <tt>grep ^msgid</tt>.
 +
::# If found,
 +
::## move tmp.pot to gnucash.pot
 +
::## merge it into the po files
 +
::## commit po files locally
 +
::## push po files plus pot file to weblate
 +
::## Cleanup (remove gnucash.pot).
  
[[Category:Translation]]
+
;General problem: [[Gitolite]] hooks can not commit.
[[Category:Development]]
+
:So an alternative could be to implement it in the normal <tt>make check</tt>:
 +
::If a ^msgid diff is found, fail with the instruction to commit the changed po[t] files.
 +
 
 +
;htdocs: almost the same as gnucash, but the sources are  *.{[p]html|php}
 +
;docs: TBD after itstools

Latest revision as of 10:28, 18 November 2021

Purpose of this page is to collect ideas to improve the Localization process of the several GnuCash components.

Motivation

It is often heard by translators, it is so hard to get a recent pot file for the one or other Gnucash component. This is the right place to sketch and evaluate ideas to improve the process.

Web Based Translation Tools

Several services for translation coordination exist:

FOSS
GlotPress
a site using the wordpress plugin, PHP based
Pootle
for localization of applications' GUIs using, uses Translate Toolkit
translatewiki.net
uses mediawiki Extension:Translate
Weblate
(suggested by Pedro (pt_PT)), uses Translate Toolkit
Zanata
site CLI, REST-API, java/js based
Proprietary
Crowdin
integrations, for FOSS free
POEditor
free for FOSS
Transifex
GSM, SaaS, for FOSS free
and several more
Checklist
VCS integration? GitHub vs. GitLab should not be an issue
Are they free? (Both meanings)

Toolkits

Translate Toolkit, partially used by aqbanking.

Implementation Thoughts

We had some discussion.

Weblate

From https://lists.gnucash.org/logs/2020/10/15.html#T15:09:05 - 19:38:30; https://lists.gnucash.org/logs/2020/10/16.html#T07:59:20 - 12:02:34

In theory you can run your own weblate instance or have a hosted project at weblate.org, which is is free for FOSS. User:Fell thinks the hosted form could attract new translators and has less administrative overhead.

Server Relation
Ideally code as primary git server should push changes to weblate.org. Weblate.org again should create PRs on github, which we then merge after review.
Status
Implemented on 2020-12-15. For the current status see Weblate.

Remaining Ideas by Repos

Each repo push it's (almost all [Exception TP]) existing po files.

ToDo
They should contain their pot file to allow users to create translations for new languages.
glossary
Got high priority, so it is listed first. Origin: gnucash:po/glossary
ToDo
  1. We should recommend to translate it first and after approval load it into Weblates glossary.
  2. Replace MsgId="*: by Msgcontext="*"\nMsgId="
Update
If gnc-glossary.txt changes,
  1. run txt-to-pot.sh
  2. msgmerge it in all po files
  3. commit and push
gnucash
Determinating string changes
Before committing changes to C, scm, … source files generate a gnucash.pot. Or we change the policy and add it to the repo.
  1. After the commit create a tmp.pot.
  2. Create a diff between both pot files filtered by grep ^msgid.
  3. If found,
    1. move tmp.pot to gnucash.pot
    2. merge it into the po files
    3. commit po files locally
    4. push po files plus pot file to weblate
    5. Cleanup (remove gnucash.pot).
General problem
Gitolite hooks can not commit.
So an alternative could be to implement it in the normal make check:
If a ^msgid diff is found, fail with the instruction to commit the changed po[t] files.
htdocs
almost the same as gnucash, but the sources are *.{[p]html|php}
docs
TBD after itstools