gettext CLI Cheat Sheet: msgcat, msgattrib, msggrep & msgcomm
An exact-semantics reference for the four PO-to-PO filters, with every claim executed against GNU gettext 0.23.1 rather than recalled. Starts from the one model that explains all four — entries keyed by (msgctxt, msgid), which is why two strings that look identical never merge — and the parallel universe of obsolete #~ entries that each tool treats differently, including the chained-pipeline case where a string deleted years ago loses its comment prefix and silently rejoins the live catalog. Then a verified matrix of the options all four share, and five corrections to things repeated everywhere: msgattrib --translated counts fuzzy and obsolete entries so your coverage metric reads higher than what ships; --empty is a no-op unless paired with --clear-fuzzy; --only-file scopes attribute manipulation rather than selecting a subset; msggrep -i is honoured with -F and silently ignored in both regex modes; and msgattrib selection flags intersect while msggrep criteria are unioned, so the same query shape means opposite things in the two tools. Plus the --more-than arithmetic behind union, intersection, symmetric difference and the two-step A minus B, why a msgcat conflict compiles cleanly with exit code 0 and ships English, a what-survives table covering comments, flags, previous-msgid, plurals and context, eleven composable recipes, and a one-screen quick reference.