Command-line Tool

Multilizer Enterprise edition ships with Multilizer command-line tool MLBuild which can help automate the localization project synchronization, translation exchange with translators, translation work and language version creation. Tool is placed on Multilizer Enterprise installation directory (e.g. C:\Program Files\Multilizer\MultilizerEnterprise).

MLBuild.exe

Syntax: MLBuild.exe command [command [command ...]] project

Where the project is a Multilizer project file (.m7p).

Commands:

  a/add
  b/build
  c/create
  e/export
  h/help
  i/import
  r/rem
  s/scan
  sc/script
  se/session
  sh/show
  q/quit
  ex/exchange
  bt/batchtext
  st/statistic
  v/validate
  ru/remove-unused
  l/language
  tv/transvalidate
To get help on a specific command, run the command without any parameters

Below you can find detailed commands description.

Add a target to existing project (a/add)

a[dd] -f: [-native:] [-lang:] <-scanner: | -settings:>
[-user:] [-pw:] [-q] project

-f:          Specify target file name (if relative path will be
             used it should be related to project file)
-native:     Specify native language for project
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-scanner:    Specify scanner short name for scanning target file.
             Eg.: -scanner:VCL.
-settings:   Specify file with scanner settings "*.scannersettings"
             (you may save this file from ML Scanner Options Dialog).
-q           Quiet mode. Suppress any output to standard output.

If "-scanner:" not specified, scanner name will be read from
scannersettings-file, "-scanner:" or/and "-settings:" keys should specified
Example: mlbuild a -f:test.exe -native:en -lang:fi -scanner:vcl test.m7p

Build localized files (b/build)
 
b[uild] [-lang:] [-usenativeinfatal] [-smart] [-xmllog] [-q] project
 
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-usenativeinfatal
             Using native string instead of translated one if validation
             test has not passed.
-q           Quiet mode. Suppress any output to standard output.
-xmllog            Writes the location of the xml log file.

Create (c)
Create empty project

c[reate] [-lang:] [-user:] [-pw:] [-q] project

-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-q           Quiet mode. Suppress any output to standard output.


Export (e/export)

e[xport] -show

Export to .m7p format:
e[xport] -f: [-settings:] [-lang:] [-status:]
[-trstatus:] [-untranslated] [-nodisabled] [-q] [-flagonly] [-noro] project

-f:          Specify target file name
-settings:   Specify file with export settings "*.exportsettings"
             (you may save this file from ML Export Wizard),
             other parametrs will be ignored, except of parameter "-f".
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-status:     Filter by status (values: act,new,chg,rem).
             Multiple values separated with semicolon. Empty means
             that all are exported.
-trstatus:   Filter by translation status (values: fuz,aut,tra,qad,rdy).
             Multiple values separated with semicolon. Empty means
             that all are exported.
-untranslated
             Also export untranslated rows.
-nodisabled  Don't send translations of disabled targets.
             By default entire project is sent.
-flagonly    Export only "flagged" rows.
-noro        Don't export read-only rows.
-q           Quiet mode. Suppress any output to standard output.

Export to 3rd-party format:

e -f: <-exporter: | -settings:>
[[-lang:] [-status:] [-trstatus:] [-untranslated] [-nodisabled] [-q]] project

-f:          Target file or exporter settings file name
             (exporter settings may saved from exporter dialog
             if you use exporter settings add "@" before file name.
             Ex.: "@tmx_exportsettings.xml").
-exporter:   Specify exporter name for export project to 3-d party format
Other parametrs have the same value as for export to M7P format


Import (i/import)
Show importer plugins installed in the system.

i[mport] -show

Import from .M7P format

i[mport] -f: [-settings:] [-native:] [-lang:] [-rowcomment:]
[-method] [-overwri:] [-trstatus:] [-trcomment:]
[-metainfo:] [-nodisabled]] [-ignorename] [-q] [-noreadonly] project

-f:          Specify imported file name
-settings:   Specify file with import settings "*.importsettings" (you may
             save this file from ML Import Wizard), other parametrs will be
             ignored.
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-native:     Specify native language for importer (default is native language
             from project).
-rowcomment: Specify how row comments are imported (values: never, overwrite,
             append). Default is overwrite.
-method:     How to import [By context=0 / By native=1 / First by context,
             then by native=2 / By context and native=3 ].
             An integer specifying import method. (Default = 2).
-overwri:    Overwrite control. [Always=0 / If translation status of imported
             string is the same or higher=1 If translation status of imported
             string is higher=2 / Never=3].
             An integer specifying when to overwrite translations. (Default = 1).
-trstatus:   Specify status for imported translations
             (values: fuz,aut,tra,qad,rdy). If not specified
             statuses from source file will be used
-trcomment:  Specify how translation comments are imported (values: never,
             overwrite, append). By default overwrite.
-metainfo:   Specifies which additional info is imported (values: ronly, max,
             exludes).
             Multiple values separated with semicolon. Default value import
             all metainfo.
-nodisabled  Don't import translations to disabled targets. By default
             translations are imported to entire project.
-ignorename  If not specified, target file name will be taking into account
             (do import only if imported target and project`s target
             have the same file name).
-q           Quiet mode. Suppress any output to standard output.
-noreadonly  If specified, importer will not overwrite read-only rows
project      Specify project file name where import translations

Import from 3rd-party format

i[mport] <-f: & -importer: | -settings:> [-method:]
[-trstatus:] [-native:] [-lang:] [-rowcomment:] [-emptycomment]
[-emptytrcomment] [-overwri:] [-trcomment] [-q] [-verbose] project

-importer:   Short name of importer (Ex.: tmx)
-f:          import file name or importer settings file name
             (importer settings may saved from importer dialog
             if you use importer settings add "@" before file name.
             Ex.: "@tmx_importsettings.xml"). You should use "nofile"
             for importers which do not need a file (e.g. GoogleImporter, MTQ).
-emptycomment: Import empty row comments when overwrite mode is selected.
-emptytrcomment: Import empty translation comments when overwrite mode
             is selected.
Other parametrs have the same value as for import from .M7P format

Example: mlbuild i -f:nofile -importer:mtq test.m7p


Scan (s/scan)
Scan source files

s[can] [-smart] [-xmllog] [-q] project

-q           Quiet mode. Suppress any output to standard output.
-verbose     If specified, importer will output which translation
             has been imported
-xmllog                 Writes the location of the xml log file.


Show (sh/show)
Shows info about installed scanners.

Exchange (ex)
Exchange to .m7x format (zipped M7P)

ex[change] -f: [-lang:] [-status:] [-trstatus:] [-untranslated]
[-nodisabled] [-q] [-flagonly] [-noro] project

-f:          Specify target file name
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-status:     Filter by status (values: act,new,chg,rem).
             Multiple values separated with semicolon. Empty means
             that all are exported.
-trstatus:   Filter by translation status (values: fuz,aut,tra,qad,rdy).
             Multiple values separated with semicolon. Empty means
             that all are exported.
-untranslated
             Also export untranslated rows.
-nodisabled  Don't send translations of disabled targets.
             By default entire project is sent.
-flagonly    Export only "flagged" rows.
-noro        Don't export read-only rows.
-q           Quiet mode. Suppress any output to standard output.


Batch text (bt/batchtext)
Use importer for export to txt-file

bt [batchtext] -f: [-native:] -lang: -c:
[-importer:]

-f:          Specify name of text file included strings for translated
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-c:          Specify name of configuration file for importer
-importer:   Short importer name
Text file with name "sourcefilenamewithoutextension_importername.txt"
where each string contain: "native;translate" will be created.


Statistics (st)
Show project statistic

st[atistic] [-f:] [-lang:] [-level:] project

-f:          Specify output report-file name.
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter
-level:      Specify statistic level (values: quick, standard, xml).
             "quick" mode prints statistic on standard output
             ("quick" mode is used by default).
             For "standard" mode html report-file will be created,
             if -f key is not specified, "Ml7StatisticReport.htm"
             will be used by default.
             For "xml" mode xml statistic report-file will be created the
             same as in Multilizer GUI.


Validate (v)
Validate project and write a log of validations

v[alidate] [-fix] [-settings:] [-lang:] project

-settings:   Specify file with validation settings (*.validationsettings), if
             not specified validations will use default settings.
-fix         Try to fix validation issues.
-lang:       Specify the language to process (for several languages use ";".
             Ex.: -lang:fi;ru;en_us).
             To process all languages, don't' specify this parameter

Exitcode:
  2          Fatal issues found by validation.
  1          Normal issues found by validation.
  0          No issues found by validation.

Examples:
  ml7build v -lang:fi myproject.m7p
             Validate Finnish language using default validation settings.
  ml7build v -settings:test.validationsettings -lang:fi myproject.m7p > qa.txt
             Validate Finnish language using validation settings specified.
             in file test.validationsettings. Write results to qa.txt.


Remove unsed (ru)
Remove rows marked as "unused" from project

ru|remove-unused project


Language (l)
The command runs through all targets in a project and sets the native
and target languages as specified. If project has translations in a language
which not specified, those are removed.

[-native:] [-lang:] project

-native         ISO code.

-lang                   A list of one or more ISO codes separated by semicolons.


Translations validation (tv)
The Translation Validation validates project translations by comparing them
with the translations returned by the importer.

-f: -importer: [-lang:] project

-importer:   Short name of importer (Ex.: tmx)
-f:          import file name or importer settings file name
             (importer settings may saved from importer dialog
             if you use importer settings add "@" before file name.
             Ex.: "@tmx_importsettings.xml"). You should use "nofile"
             for importers which do not need a file (e.g. GoogleImporter).
-lang      A list of one or more ISO codes separated by semicolons.

Also mlbuild tool supports scripts and session modes which allow to execute commands one by one without need to call tool each time. I.e. if you wish to work in session mode you just type:

mlbuild se

and after that you can specify commands without "mlbuild" part. To quit session type q/quit.

Also you can write sequence of commands to plain text file and then specify it with as parameter for sc/script command:

mlbuild sc commands.txt

inside commands.txt you can write sequence like that:

c test.m7p
a -f:test.exe -lang:fi test.m7p
s test.m7p
i -f:nofile -importer:GoogleImporter test.m7p
b test.m7p

This script creates project file called test.m7p, then adds target called test.exe with Finnish as target language (by default Native is English, scanner will be detected automatically) to this project, scans target, imports translations from GoogleImporter and builds translated file.

To remark row in script file you can use command r/rem.