MSGATTRIB(1)

πŸ’– MSGATTRIB(1) β€” msgattrib πŸ’–

okay bestie, gather round, because this little icon of a tool does attribute matching and manipulation on message catalogs and honestly? it eats. ✨


🌸 SYNOPSIS 🌸

msgattrib [OPTION] [INPUTFILE]

πŸ¦‹ DESCRIPTION πŸ¦‹

So basically, msgattrib filters the messages of a translation catalog according to their attributes, and β€” plot twist β€” it also manipulates the attributes. it's giving glow-up for your .po file, fr fr. πŸ’…

mandatory arguments to long options are mandatory for short options too. (yes queen, that's just how it is.)

πŸŽ€ Input file location:

  • INPUTFILE β€” the input PO file, your main character 🫢
  • -D, --directory=DIRECTORY β€” add DIRECTORY to list for input files search

if no input file is given or if it is -, standard input is read. lowkey convenient, ngl. 🌈

πŸ“ Output file location:

  • -o, --output-file=FILE β€” write output to specified file

the results are written to standard output if no output file is specified or if it is -. periodt. πŸ’œ

⭐ Message selection:

  • --translated β€” keep translated, remove untranslated messages
  • --untranslated β€” keep untranslated, remove translated messages
  • --no-fuzzy β€” remove 'fuzzy' marked messages
  • --only-fuzzy β€” keep 'fuzzy' marked messages
  • --no-obsolete β€” remove obsolete #~ messages
  • --only-obsolete β€” keep obsolete #~ messages

it's giving ✨vibe check✨ but for messages. only the ones you want get to stay. πŸ’€

πŸ‘‘ Attribute manipulation:

  • --set-fuzzy β€” set all messages 'fuzzy'
  • --clear-fuzzy β€” set all messages non-'fuzzy'
  • --set-obsolete β€” set all messages obsolete
  • --clear-obsolete β€” set all messages non-obsolete
  • --previous β€” when setting 'fuzzy', keep previous msgids of translated messages.
  • --clear-previous β€” remove the "previous msgid" from all messages
  • --empty β€” when removing 'fuzzy', also set msgstr empty
  • --only-file=FILE.po β€” manipulate only entries listed in FILE.po
  • --ignore-file=FILE.po β€” manipulate only entries not listed in FILE.po
  • --fuzzy β€” synonym for --only-fuzzy --clear-fuzzy
  • --obsolete β€” synonym for --only-obsolete --clear-obsolete

ngl those last two are the "two-in-one combo deal" of flags. iconic behavior honestly. πŸŽ€

🧚 Input file syntax:

  • -P, --properties-input β€” input file is in Java .properties syntax
  • --stringtable-input β€” input file is in NeXTstep/GNUstep .strings syntax

🌸 Output details:

  • --color β€” use colors and other text attributes always
  • --color=WHEN β€” use colors and other text attributes if WHEN. WHEN may be 'always', 'never', 'auto', or 'html'.
  • --style=STYLEFILE β€” specify CSS style rule file for --color
  • -e, --no-escape β€” do not use C escapes in output (default)
  • -E, --escape β€” use C escapes in output, no extended chars
  • --force-po β€” write PO file even if empty
  • -i, --indent β€” write the .po file using indented style
  • --no-location β€” do not write '#: filename:line' lines
  • -n, --add-location β€” generate '#: filename:line' lines (default)
  • --strict β€” write out strict Uniforum conforming .po file
  • -p, --properties-output β€” write out a Java .properties file
  • --stringtable-output β€” write out a NeXTstep/GNUstep .strings file
  • -w, --width=NUMBER β€” set output page width
  • --no-wrap β€” do not break long message lines, longer than the output page width, into several lines
  • -s, --sort-output β€” generate sorted output
  • -F, --sort-by-file β€” sort output by file location

πŸ’œ Informative output:

  • -h, --help β€” display this help and exit
  • -V, --version β€” output version information and exit

πŸ’Œ AUTHOR πŸ’Œ

Written by Bruno Haible. (shoutout to the legend 🫢)


πŸ› REPORTING BUGS πŸ›

found a bug? not the vibe. report bugs in the bug tracker at <https://savannah.gnu.org/projects/gettext> or by email to <bug-gettext@gnu.org>.


Copyright Β© 2001-2026 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>

This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

bestie that last part is not a joke β€” there is genuinely NO WARRANTY, to the extent permitted by law. πŸ’€ don't come for them if it breaks.

πŸ‘€ SEE ALSO πŸ‘€

The full documentation for msgattrib is maintained as a Texinfo manual. If the info and msgattrib programs are properly installed at your site, the command

info msgattrib

should give you access to the complete manual. go read it, it's giving academic but make it cute. πŸ“šβœ¨


and that's the whole page, bestie! this is GNU gettext-tools 1.0, dated January 2026 β€” mwah, slay, go filter some catalogs. πŸ’…πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from