forked from itstool/itstool
-
Notifications
You must be signed in to change notification settings - Fork 0
/
itstool.1.in
120 lines (85 loc) · 3.04 KB
/
itstool.1.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
.TH "ITSTOOL" "1" "December 2013" "itstool @VERSION@"
.SH "NAME"
itstool \- convert between XML and PO using ITS
.SH "SYNOPSIS"
itstool [OPTIONS] XMLFILES...
.br
itstool \fB\-m\fR <MOFILE> [OPTIONS] XMLFILES...
.br
itstool \fB\-j\fR <XMLFILE> [OPTIONS] MOFILES...
.SH "DESCRIPTION"
\fBitstool \fR extracts messages from XML files and outputs PO template files,
then merges translations from MO files to create translated XML files. It
determines what to translate and how to chunk it into messages using the W3C
Internationalization Tag Set (ITS).
To extract messages from XML files \fBXMLFILES\fR and output them to \fBOUT.pot\fR:
.BR "itstool \-o OUT.pot XMLFILES"
After merging with existing translations or translating strings, generate an
MO file with \fBmsgfmt(1)\fR, then output translated files to the directory
\fBDIR\fR:
.BR "itstool \-m OUT.mo \-o DIR XMLFILES"
You can also create a single multilingual XML output file using an input XML
file and a set of MO files:
.BR "itstool \-j FILE.xml \-o OUT.xml MOFILES"
ITS definitions are loaded from the built-in rules, rules embedded in the source
XML files, files passed with the \fB-i\fR option, and ITS attributes in the source
XML files. Later definitions take precedence. You can disable built-in rules by
passing the \fB-n\fR option.
.SH "OPTIONS"
.SS "Extracting"
.IP "\fB\-o \fIOUT.pot\fR" 4
.PD 0
.IP "\fB\-\-out \fIOUT.pot\fR" 4
output PO template to the file \fBOUT.pot\fR
.SS "Merging"
.IP "\fB\-m \fIMOFILE\fR \fIXMLFILES\fR" 4
.PD 0
.IP "\fB\-\-merge \fIMOFILE\fR \fIXMLFILES\fR" 4
merge from an MO file \fBMOFILE\fR and output translated XML files for source \fBXMLFILES\fR
.IP "\fB\-l \fILANG\fR" 4
.PD 0
.IP "\fB\-\-lang \fILANG \fR" 4
explicitly set the language code output to XML
.IP "\fB\-o \fIOUT\fR" 4
.PD 0
.IP "\fB\-\-out \fIOUT \fR" 4
output XML files in the directory \fBOUT\fR
.SS "Joining"
.IP "\fB\-j \fXMLIFILE\fR \fIMOFILES\fR" 4
.PD 0
.IP "\fB\-\-join \fIXMLFILE\fR \fIMOFILES\fR" 4
join translations from \fBMOFILES\fR into a multilingual file based on source \fBXMLFILE\fR
.IP "\fB\-o \fIOUT.xml\fR" 4
.PD 0
.IP "\fB\-\-out \fIOUT.xml\fR" 4
output to the XML file \fBOUT.xml\fR
.SS "Common"
.IP "\fB\-i \fIITS\fR" 4
.PD 0
.IP "\fB\-\-its \fIITS\fR" 4
load the ITS rules in the file \fBITS\fR (can specify multiple times)
.IP "\fB\-n\fR" 4
.PD 0
.IP "\fB\-\-no\-builtins\fR" 4
do not apply the built-in ITS rules that ship with itstool
.IP "\fB\-s\fR" 4
.PD 0
.IP "\fB\-\-strict\fR" 4
exit with error when PO files contain broken XML
.IP "\fB\-d\fR" 4
.PD 0
.IP "\fB\-\-load\-dtd\fR" 4
load external DTDs used by input XML files
.IP "\fB\-k\fR" 4
.PD 0
.IP "\fB\-\-keep\-entities\fR" 4
keep entity references unexpanded in PO files
.IP "\fB\-p \fINAME VALUE\fR" 4
.PD 0
.IP "\fB\-\-param \fINAME VALUE\fR" 4
define ITS parameter \fBNAME\fR to the value \fBVALUE\fR (can specify multiple times)
.SH "AUTHOR"
Shaun McCance <[email protected]>
.SH "SEE ALSO"
More documentation for \fBitstool\fR is maintained online. For more information, see:
.BR "http://itstool.org/documentation/"