On Ubuntu 14.04, cat
can display Chinese characters correctly.
But in vi
and less
Chinese characters can't display correctly.
Solution:
Run export LC_ALL=en_US.UTF-8
before git log
.
If it works, add this line into /etc/environment.
If it doesn't work, run export LANG=en_US.UTF-8
.
If it doesn't work, run apt-get install language-pack-en-base
.
In vim, run set enc=utf-8
.
Ref:
http://askubuntu.com/questions/162391/how-do-i-fix-my-locale-issue
http://stackoverflow.com/questions/5166652/how-to-view-utf-8-characters-in-vim-or-gvim