Posts Tagged ‘utf8’

MySQL UTF8 Import

Saturday, March 15th, 2008
mysql -u root --default_character_set utf8 -p database < import.sql

沒有亂碼了 [aha

簡體 UTF8 -> 繁體/正體 UTF8

Saturday, March 15th, 2008

Encode-CNmap 是好朋友
雖然字表沒有完整,但是大部份都有轉換成功,而且使用上也不錯簡單
轉換文字檔案:
cnmap -u2cb5 utf8.txt > utf8-cntrad.txt

對於懶得在 Python 下面 implement 繁簡轉換的人(me?)實在很好用:

import commands
s = commands.getoutput("echo '简体中文' | cnmap -ucb5")
print s

說真的,這方法最好別用 XD

輕鬆將 BIG5/GBK 檔名轉成 UTF-8

Saturday, January 5th, 2008

剛 Google 了一下發現 convmv 是超級好朋友 (l)

使用如下: convmv -f big5 -t utf8 -r *

會先出現一次測試 output 如果都沒有錯誤的話會提示說加個 –notest 正式改名

所有 big5/gbk 檔名一次輕鬆解決

All Rights Reserved Copyright © 2008 Design by StyleShout and Clazh