Displaying and edititing Simplified Chinese in Mac OS X shell can be a pain, the following show the correct way to make this possible.
1. Edit ~/.profile, add:
export LANG=zh_CN export LC_ALL=zh_CN
2. Set terminal encoding to:
EUC_CN
3. Edit ~/.inputrc, add:
set meta-flag on set input-meta on set output-meta on set convert-meta off
3. While in VI, enter following commands:
:set encoding :set fileencoding
