Transform Framework
LRM supports a number of file types out of the box (See Supported Resource Bundles). However, other file types may represent user facing strings to be translated. In that case, some customization is required to on-board those projects. The bash script transform framework facilitates the customization.
Analyze the file types
If the file types fall into a category not supported by LRM out of the box, the first thing to do is to see what is the closest file types supported by LRM.
Use the transform framework
The transform framework needs three scripts in order to fit in with LRM. The three scripts need to be under the $JENKINS_HOME/lingoport/transform/<nameoftransform>/
directory.
The <nameoftransform> must be indicative of the type of transformation to apply. For instance, it could be loc
to handle .loc files (see below). In that case, three scripts will need to be under /var/lib/jenkins/lingoport/transform/loc
for a typical installation where the jenkins
user is under /var/lib/jenkins
Example: .loc files
Say the repository contains resource files like the following hmUiMessage.loc
file:
;hmUiMessage.loc ;********************************************************************* #include hmUiMain.loc ;********************************************************************* message1 The first message message2 The second message message3 The third message message4 The fourth message
The file may not be in ASCII or UTF-8 format; For instance this file is in UTF-16BE
A supported file format that is close to this one is properties
.
==