Changes between Version 29 and Version 30 of BluePrint/Translation


Ignore:
Timestamp:
08/19/13 14:12:39 (8 years ago)
Author:
nownikhil
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • BluePrint/Translation

    v29 v30  
    7878
    7979== Pootle Integration ==
    80    * Initially we merge the translations between pootle and py such that translations in py are given preference. If pootle has translations that py doesn't,  then those get added. This merged set of strings is reflected in both pootle and py. This creates an initial sync between the two.
     80   * Initially we merge the translations between pootle and py such that translations in py are given preference. This merged set of strings is reflected in both pootle and py. This creates an initial sync between the two.
    8181
    8282   * Now when someone requests for an Excel file for translation, we check pootle for any updated strings since last sync. If any, we merge them to py files and provide the translator with an updated set of strings in the Excel file. Hence this way py is kept in sync with pootle regularly.
    8383
    84    * After a csv file is submitted to Eden after translations,  we update both py and pootle with the changes. (Anything changed in csv implies earlier translation from pootle has to be overwritten).
     84   * After a csv file is submitted to Eden after translations, we update both py and pootle with the changes. (Anything changed in csv implies earlier translation from pootle has to be overwritten).
     85
     86   * Note : Strings are never removed from pootle, even if they are removed from the py files.
    8587
    8688   * Implementation Details:
    87        * first --
     89       * Function merge_pootle takes 2 arguments (language_code, preference). Preference defines which is given preference in case of a conflict (either po or py).
     90
     91       * Function download_strings takes the language_code and returns pootle strings and python strings in a tuple.
     92
     93       * Function merge_strings takes 2 set of strings and merges them on the basis of preference.
     94
     95       * Function upload_to_pootle takes language_code, a pootle file and uploads the pootle file to Sahana server on pootle using overwrite option. Mechanize library of python has been used to implement this.
    8896
    8997== Other Links ==