summaryrefslogtreecommitdiff
path: root/src/po/cleanup.vim
blob: cb697e8b1ec530830ce8a4a9cdda40ecbb1541b1 (plain)
1
2
3
4
5
6
7
" Vim script to cleanup a .po file: comment-out fuzzy and empty messages.
" Make sure there is a space before the string (required for Solaris).
" Requires Vim 6.0 (because of multi-line search patterns).
g/^#, fuzzy\(, .*\)\=\nmsgid ""\@!/.+1,/^$/-1s/^/#\~ /
g/^msgstr"/s//msgstr "/
g/^msgid"/s//msgid "/
g/^msgstr ""\(\n"\)\@!/?^msgid?,.s/^/#\~ /