" This po.vimrc is for vim 6.0. If you use vim 5.x, changing is easy. " Just do next two command: " :%s/^setl/set/g " :%s///g " Then it will work for vim 5.5 or later. Don't know it work less than " 5.5. " And if you save the po file, it automatically change the PO revision " date and author. If you want to use it, you should change email addr. " ,fm and ,ff will be useful. " regards, " namsh " po.vimrc: VIM resource for 'po' file editing. set com= set path=.,..,../src,, " find a non-translated msg string nmap ,fm :call FindNonTransMsg()z. " find fuzzy and remove nmap ,ff :call FindFuzzyErase() " locate fuzzy and erase nmap ,le :call FindFuzzyErase()}?^msgstrf"lc}" " duplicate the original msg. nmap ,fd }?^msgstrf"ld}?^msgidf"ly/^msgstrnf"pNf"l " erase the translated message nmap ,fe }?^msgstrf"lc}" " perform language dependent checks on strings nmap ,fc :!msgfmt --check % " show statistics nmap ,fs :!msgfmt --statistics % " commit current file nmap ,ci :!cvs ci -m '' % " goto file which contains the current string nmap ,gf {/^#: 02f:l"aye0f w:a function! FindNonTransMsg() let lnum = line(".") + 1 let enum = line("$") let found = 0 while lnum < enum let line = getline(lnum) let lnum = lnum + 1 if line == "msgstr \"\"" let blank = getline(lnum) if blank == "" let found = found + 1 exec "normal " . lnum . "ggk" let lnum = enum endif let lnum = lnum + 1 endif endwhile if found < 1 echo "Cannot find non-translated msg" endif endfun func! FindFuzzyErase() let lnum = line(".") + 1 let enum = line("$") while lnum < enum let line = getline(lnum) if line =~ "#, fuzzy" exec "normal " .lnum. "gg" if line =~ "#, fuzzy, " exec "normal ^ldt," else exec "normal dd" endif /^msgstr exec "norm z.f\"l" echohl WarningMsg | echo "You may want to edit this" | echohl None return endif let lnum = lnum + 1 endwhile echo "There's no fuzzy" endfun " Update the time of the 'PO-Revision-Date'. imap mG:r!date --utc +'\%Y-\%m-\%d \%T'"gd$dd`G"gpa nmap_CT mCHmH1G/^"PO-Revision-Date:f:wct\+0200 \j0f:llct\Keld Simonsen 'Hz`C augroup local_rc au! " PO revision date update au BufWritePre,FileWritePre ko.po :norm _CT augroup END