开发者

How can I preserve punctuation characters when using iconv?

The characters «, », , and several others disappear because I specify //TRANSLIT when converting to UTF-8 from Latin-1/CP1251:

iconv -f utf-8 -t latin1//TRANSLIT < in.sql | iconv -f cp1251//TRANSLIT -t utf-8 > out.sql

The gets converted to a ' since it isn't in Latin1. Is there a way to keep the characters somehow intact?

So far I've been manually keeping track and replacing them with CONSTANTSLIKETHIS mapped to letters, and I d开发者_开发技巧o manual vim replacements after the conversion process is done.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜