LinuxCommandLibrary

msguniq

removes duplicate translations from PO files

TLDR

Remove duplicate messages

$ msguniq [input.po] -o [output.po]
copy
Use first occurrence
$ msguniq -u [input.po] -o [output.po]
copy
Report duplicates
$ msguniq -d [input.po]
copy
Sort output
$ msguniq -s [input.po] -o [output.po]
copy
Unique by msgid and msgctxt
$ msguniq --use-first [input.po] -o [output.po]
copy

SYNOPSIS

msguniq [options] [inputfile]

DESCRIPTION

msguniq removes duplicate translations from PO files. It's part of GNU gettext.
The tool unifies message entries. Handles duplicates by combining or selecting.

PARAMETERS

INPUTFILE

PO file to process.
-o FILE
Output file.
-u
Keep only unique messages.
-d
Report duplicate messages.
-s
Sort output.
--use-first
Use first of duplicates.
--help
Display help information.

CAVEATS

Part of gettext-tools. Different duplicates merged. May need manual review.

HISTORY

msguniq is part of GNU gettext, helping maintain clean translation files.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community