source insight 下看不了utf-8中文字符
2013-08-26 20:34
92 查看
utf-8中文在source insight中显示为乱码,写了一个简单脚本,在linux下将代码转换为GBK格式,然后在source insight下正常查看。
保存为conv.sh 使用方法 ./conv.sh dir
#!/bin/sh function conv() { echo "Converting $1" enca -L zh_CN -x GBK $1 } function walk() { for file in `ls $1` do if [ -d $1"/"$file ] then walk $1"/"$file else conv $1"/"$file fi done } walk $1
保存为conv.sh 使用方法 ./conv.sh dir
相关文章推荐
- source insight 下看不了utf-8中文字符
- UTF-8下面截取中文字符。
- Android 中文字符转UTF-8编码
- Android 中文字符转UTF-8编码
- 中文字符编码之GBK,UTF-16和UTF-8
- python利用utf-8编码判断中文英文字符
- 【Python开发】Url中文字符时记得转码edcode("utf-8")
- Robot Framework RIDE中的字符转换、中文、python的gbk解码 unicode('${org_name}',"utf-8")
- UTF-8和GBK等中文字符编码格式介绍及相互转换
- 在UTF-8字符集中,一个中文字并不是2字节
- PHP匹配UTF-8中文字符的正则表达式
- URL拼接中文字符转UTF-8编码
- 在UTF-8字符集中,一个中文字并不是2字节
- 字符编码——在python2中如何将txt中的utf-8转换成中文
- 解决string.len 处理 utf-8 中文字符不正确的问题
- python利用utf-8编码判断中文英文字符(转)
- Android 中文字符转UTF-8编码
- Python中关于coding=utf-8以及中文字符前加u的解释
- smarty截取中文字符乱码问题?gb2312-------utf-8