2 @cindex @code{msgattrib} program, usage
4 msgattrib [@var{option}] [@var{inputfile}]
7 @cindex filter messages according to attributes
8 @cindex attribute manipulation
9 The @code{msgattrib} program filters the messages of a translation catalog
10 according to their attributes, and manipulates the attributes.
12 @subsection Input file location
18 @item -D @var{directory}
19 @itemx --directory=@var{directory}
20 @opindex -D@r{, @code{msgattrib} option}
21 @opindex --directory@r{, @code{msgattrib} option}
22 Add @var{directory} to the list of directories. Source files are
23 searched relative to this list of directories. The resulting @file{.po}
24 file will be written relative to the current directory, though.
28 If no @var{inputfile} is given or if it is @samp{-}, standard input is read.
30 @subsection Output file location
34 @itemx --output-file=@var{file}
35 @opindex -o@r{, @code{msgattrib} option}
36 @opindex --output-file@r{, @code{msgattrib} option}
37 Write output to specified file.
41 The results are written to standard output if no output file is specified
44 @subsection Message selection
48 @opindex --translated@r{, @code{msgattrib} option}
49 Keep translated messages, remove untranslated messages.
52 @opindex --untranslated@r{, @code{msgattrib} option}
53 Keep untranslated messages, remove translated messages.
56 @opindex --no-fuzzy@r{, @code{msgattrib} option}
67 @opindex --only-fuzzy@r{, @code{msgattrib} option}
75 marked messages, remove all other messages.
78 @opindex --no-obsolete@r{, @code{msgattrib} option}
79 Remove obsolete #~ messages.
82 @opindex --only-obsolete@r{, @code{msgattrib} option}
83 Keep obsolete #~ messages, remove all other messages.
87 @subsection Attribute manipulation
89 @cindex modify message attributes
90 Attributes are modified after the message selection/removal has been
91 performed. If the @samp{--only-file} or @samp{--ignore-file} option is
92 specified, the attribute modification is applied only to those messages
93 that are listed in the @var{only-file} and not listed in the
98 @opindex --set-fuzzy@r{, @code{msgattrib} option}
108 @opindex --clear-fuzzy@r{, @code{msgattrib} option}
118 @opindex --set-obsolete@r{, @code{msgattrib} option}
119 Set all messages obsolete.
121 @item --clear-obsolete
122 @opindex --clear-obsolete@r{, @code{msgattrib} option}
123 Set all messages non-obsolete.
126 @opindex --previous@r{, @code{msgattrib} option}
134 mark, keep ``previous msgid'' of translated messages.
136 @item --clear-previous
137 @opindex --clear-previous@r{, @code{msgattrib} option}
138 Remove the ``previous msgid'' (@samp{#|}) comments from all messages.
140 @item --only-file=@var{file}
141 @opindex --only-file@r{, @code{msgattrib} option}
142 Limit the attribute changes to entries that are listed in @var{file}.
143 @var{file} should be a PO or POT file.
145 @item --ignore-file=@var{file}
146 @opindex --ignore-file@r{, @code{msgattrib} option}
147 Limit the attribute changes to entries that are not listed in @var{file}.
148 @var{file} should be a PO or POT file.
151 @opindex --fuzzy@r{, @code{msgattrib} option}
152 Synonym for @samp{--only-fuzzy --clear-fuzzy}: It keeps only the fuzzy
153 messages and removes their
163 @opindex --obsolete@r{, @code{msgattrib} option}
164 Synonym for @samp{--only-obsolete --clear-obsolete}: It keeps only the
165 obsolete messages and makes them non-obsolete.
169 @subsection Input file syntax
173 @itemx --properties-input
174 @opindex -P@r{, @code{msgattrib} option}
175 @opindex --properties-input@r{, @code{msgattrib} option}
176 Assume the input file is a Java ResourceBundle in Java @code{.properties}
177 syntax, not in PO file syntax.
179 @item --stringtable-input
180 @opindex --stringtable-input@r{, @code{msgattrib} option}
181 Assume the input file is a NeXTstep/GNUstep localized resource file in
182 @code{.strings} syntax, not in PO file syntax.
186 @subsection Output details
188 @c --no-escape and --escape omitted on purpose. They are not useful.
192 @itemx --color=@var{when}
193 @opindex --color@r{, @code{msgattrib} option}
194 Specify whether or when to use colors and other text attributes.
195 See @ref{The --color option} for details.
197 @item --style=@var{style_file}
198 @opindex --style@r{, @code{msgattrib} option}
199 Specify the CSS style rule file to use for @code{--color}.
200 See @ref{The --style option} for details.
203 @opindex --force-po@r{, @code{msgattrib} option}
204 Always write an output file even if it contains no message.
208 @opindex -i@r{, @code{msgattrib} option}
209 @opindex --indent@r{, @code{msgattrib} option}
210 Write the .po file using indented style.
213 @opindex --no-location@r{, @code{msgattrib} option}
214 Do not write @samp{#: @var{filename}:@var{line}} lines.
217 @itemx --add-location
218 @opindex -n@r{, @code{msgattrib} option}
219 @opindex --add-location@r{, @code{msgattrib} option}
220 Generate @samp{#: @var{filename}:@var{line}} lines (default).
223 @opindex --strict@r{, @code{msgattrib} option}
224 Write out a strict Uniforum conforming PO file. Note that this
225 Uniforum format should be avoided because it doesn't support the
229 @itemx --properties-output
230 @opindex -p@r{, @code{msgattrib} option}
231 @opindex --properties-output@r{, @code{msgattrib} option}
232 Write out a Java ResourceBundle in Java @code{.properties} syntax. Note
233 that this file format doesn't support plural forms and silently drops
236 @item --stringtable-output
237 @opindex --stringtable-output@r{, @code{msgattrib} option}
238 Write out a NeXTstep/GNUstep localized resource file in @code{.strings} syntax.
239 Note that this file format doesn't support plural forms.
241 @item -w @var{number}
242 @itemx --width=@var{number}
243 @opindex -w@r{, @code{msgattrib} option}
244 @opindex --width@r{, @code{msgattrib} option}
245 Set the output page width. Long strings in the output files will be
246 split across multiple lines in order to ensure that each line's width
247 (= number of screen columns) is less or equal to the given @var{number}.
250 @opindex --no-wrap@r{, @code{msgattrib} option}
251 Do not break long message lines. Message lines whose width exceeds the
252 output page width will not be split into several lines. Only file reference
253 lines which are wider than the output page width will be split.
257 @opindex -s@r{, @code{msgattrib} option}
258 @opindex --sort-output@r{, @code{msgattrib} option}
259 Generate sorted output. Note that using this option makes it much harder
260 for the translator to understand each message's context.
263 @itemx --sort-by-file
264 @opindex -F@r{, @code{msgattrib} option}
265 @opindex --sort-by-file@r{, @code{msgattrib} option}
266 Sort output by file location.
270 @subsection Informative output
275 @opindex -h@r{, @code{msgattrib} option}
276 @opindex --help@r{, @code{msgattrib} option}
277 Display this help and exit.
281 @opindex -V@r{, @code{msgattrib} option}
282 @opindex --version@r{, @code{msgattrib} option}
283 Output version information and exit.