transmision: upgrade 2.22 -> 2.31
[tomato.git] / release / src / router / gettext / gettext-tools / doc / msgmerge.texi
blob90dccd5b9c05598daab11abc5e96290ce3453529
1 @pindex msgmerge
2 @cindex @code{msgmerge} program, usage
3 @example
4 msgmerge [@var{option}] @var{def}.po @var{ref}.pot
5 @end example
7 The @code{msgmerge} program merges two Uniforum style .po files together.
8 The @var{def}.po file is an existing PO file with translations which will
9 be taken over to the newly created file as long as they still match;
10 comments will be preserved, but extracted comments and file positions will
11 be discarded.  The @var{ref}.pot file is the last created PO file with
12 up-to-date source references but old translations, or a PO Template file
13 (generally created by @code{xgettext}); any translations or comments
14 in the file will be discarded, however dot comments and file positions
15 will be preserved.  Where an exact match cannot be found, fuzzy matching
16 is used to produce better results.
18 @subsection Input file location
20 @table @samp
21 @item @var{def}.po
22 Translations referring to old sources.
24 @item @var{ref}.pot
25 References to the new sources.
27 @item -D @var{directory}
28 @itemx --directory=@var{directory}
29 @opindex -D@r{, @code{msgmerge} option}
30 @opindex --directory@r{, @code{msgmerge} option}
31 Add @var{directory} to the list of directories.  Source files are
32 searched relative to this list of directories.  The resulting @file{.po}
33 file will be written relative to the current directory, though.
35 @item -C @var{file}
36 @itemx --compendium=@var{file}
37 @opindex -C@r{, @code{msgmerge} option}
38 @opindex --compendium@r{, @code{msgmerge} option}
39 Specify an additional library of message translations.  @xref{Compendium}.
40 This option may be specified more than once.
42 @end table
44 @subsection Operation mode
46 @table @samp
47 @item -U
48 @itemx --update
49 @opindex -U@r{, @code{msgmerge} option}
50 @opindex --update@r{, @code{msgmerge} option}
51 Update @var{def}.po.  Do nothing if @var{def}.po is already up to date.
53 @end table
55 @subsection Output file location
57 @table @samp
58 @item -o @var{file}
59 @itemx --output-file=@var{file}
60 @opindex -o@r{, @code{msgmerge} option}
61 @opindex --output-file@r{, @code{msgmerge} option}
62 Write output to specified file.
64 @end table
66 @cindex standard output, and @code{msgmerge} program
67 The results are written to standard output if no output file is specified
68 or if it is @samp{-}.
70 @subsection Output file location in update mode
72 The result is written back to @var{def}.po.
74 @table @samp
75 @item --backup=@var{control}
76 @opindex --backup@r{, @code{msgmerge} option}
77 @cindex backup old file, and @code{msgmerge} program
78 Make a backup of @var{def}.po
80 @item --suffix=@var{suffix}
81 @opindex --suffix@r{, @code{msgmerge} option}
82 Override the usual backup suffix.
84 @end table
86 @cindex version control for backup files, @code{msgmerge}
87 The version control method may be selected via the @code{--backup} option
88 or through the @code{VERSION_CONTROL} environment variable.  Here are the
89 values:
91 @table @samp
92 @item none
93 @itemx off
94 Never make backups (even if @code{--backup} is given).
96 @item numbered
97 @itemx t
98 Make numbered backups.
100 @item existing
101 @itemx nil
102 Make numbered backups if numbered backups for this file already exist,
103 otherwise make simple backups.
105 @item simple
106 @itemx never
107 Always make simple backups.
109 @end table
111 The backup suffix is @samp{~}, unless set with @code{--suffix} or the
112 @code{SIMPLE_BACKUP_SUFFIX} environment variable.
114 @subsection Operation modifiers
116 @table @samp
117 @item -m
118 @itemx --multi-domain
119 @opindex -m@r{, @code{msgmerge} option}
120 @opindex --multi-domain@r{, @code{msgmerge} option}
121 Apply @var{ref}.pot to each of the domains in @var{def}.po.
123 @item -N
124 @itemx --no-fuzzy-matching
125 @opindex -N@r{, @code{msgmerge} option}
126 @opindex --no-fuzzy-matching@r{, @code{msgmerge} option}
127 Do not use fuzzy matching when an exact match is not found.  This may speed
128 up the operation considerably.
129 @end table
131 @subsection Input file syntax
133 @table @samp
134 @item -P
135 @itemx --properties-input
136 @opindex -P@r{, @code{msgmerge} option}
137 @opindex --properties-input@r{, @code{msgmerge} option}
138 Assume the input files are Java ResourceBundles in Java @code{.properties}
139 syntax, not in PO file syntax.
141 @item --stringtable-input
142 @opindex --stringtable-input@r{, @code{msgmerge} option}
143 Assume the input files are NeXTstep/GNUstep localized resource files in
144 @code{.strings} syntax, not in PO file syntax.
146 @end table
148 @subsection Output details
150 @c --no-escape and --escape omitted on purpose.  They are not useful.
152 @table @samp
153 @item --force-po
154 @opindex --force-po@r{, @code{msgmerge} option}
155 Always write an output file even if it contains no message.
157 @item -i
158 @itemx --indent
159 @opindex -i@r{, @code{msgmerge} option}
160 @opindex --indent@r{, @code{msgmerge} option}
161 Write the .po file using indented style.
163 @item --no-location
164 @opindex --no-location@r{, @code{msgmerge} option}
165 Do not write @samp{#: @var{filename}:@var{line}} lines.
167 @item --add-location
168 @opindex --add-location@r{, @code{msgmerge} option}
169 Generate @samp{#: @var{filename}:@var{line}} lines (default).
171 @item --strict
172 @opindex --strict@r{, @code{msgmerge} option}
173 Write out a strict Uniforum conforming PO file.  Note that this
174 Uniforum format should be avoided because it doesn't support the
175 GNU extensions.
177 @item -p
178 @itemx --properties-output
179 @opindex -p@r{, @code{msgmerge} option}
180 @opindex --properties-output@r{, @code{msgmerge} option}
181 Write out a Java ResourceBundle in Java @code{.properties} syntax.  Note
182 that this file format doesn't support plural forms and silently drops
183 obsolete messages.
185 @item --stringtable-output
186 @opindex --stringtable-output@r{, @code{msgmerge} option}
187 Write out a NeXTstep/GNUstep localized resource file in @code{.strings} syntax.
188 Note that this file format doesn't support plural forms.
190 @item -w @var{number}
191 @itemx --width=@var{number}
192 @opindex -w@r{, @code{msgmerge} option}
193 @opindex --width@r{, @code{msgmerge} option}
194 Set the output page width.  Long strings in the output files will be
195 split across multiple lines in order to ensure that each line's width
196 (= number of screen columns) is less or equal to the given @var{number}.
198 @item --no-wrap
199 @opindex --no-wrap@r{, @code{msgmerge} option}
200 Do not break long message lines.  Message lines whose width exceeds the
201 output page width will not be split into several lines.  Only file reference
202 lines which are wider than the output page width will be split.
204 @item -s
205 @itemx --sort-output
206 @opindex -s@r{, @code{msgmerge} option}
207 @opindex --sort-output@r{, @code{msgmerge} option}
208 @cindex sorting @code{msgmerge} output
209 Generate sorted output.  Note that using this option makes it much harder
210 for the translator to understand each message's context.
212 @item -F
213 @itemx --sort-by-file
214 @opindex -F@r{, @code{msgmerge} option}
215 @opindex --sort-by-file@r{, @code{msgmerge} option}
216 Sort output by file location.
218 @end table
220 @subsection Informative output
222 @table @samp
223 @item -h
224 @itemx --help
225 @opindex -h@r{, @code{msgmerge} option}
226 @opindex --help@r{, @code{msgmerge} option}
227 Display this help and exit.
229 @item -V
230 @itemx --version
231 @opindex -V@r{, @code{msgmerge} option}
232 @opindex --version@r{, @code{msgmerge} option}
233 Output version information and exit.
235 @item -v
236 @itemx --verbose
237 @opindex -v@r{, @code{msgmerge} option}
238 @opindex --verbose@r{, @code{msgmerge} option}
239 Increase verbosity level.
241 @item -q
242 @itemx --quiet
243 @itemx --silent
244 @opindex -q@r{, @code{msgmerge} option}
245 @opindex --quiet@r{, @code{msgmerge} option}
246 @opindex --silent@r{, @code{msgmerge} option}
247 Suppress progress indicators.
249 @end table