ls and cd command don't use the same encoding
Huang Bambo
bambo.huang@gmail.com
Mon Nov 9 09:14:00 GMT 2009
Under 1.7.0-63,64
With mintty
export LANG=en_US.UTF-8
export LC_TYPE=zh_CN.UTF-8
ls can list some directory in Chinese but cd command can't enter it.
If I set encoding to GBK, mintty works fine but ssh can't do so then.
$ cd /tmp
[Bambo@revenco-bambo /tmp]
$ ls
中文
[Bambo@revenco-bambo /tmp]
$ cd ▒▒▒▒/ (I use tab
key to auto fill this line)
[Bambo@revenco-bambo /tmp/▒▒▒▒]
$ cd ..
[Bambo@revenco-bambo /tmp]
$ cd 中文 (I input
the directory name, but can't enter)
-bash: cd: 中文: No such file or directory
[Bambo@revenco-bambo /tmp]
$ env | grep LAN
NLS_LANG=AMERICAN_AMERICA.ZHS32GB18030
LANG=en_US.UTF-8
[Bambo@revenco-bambo /tmp]
$ env | grep LC
LC_TYPE=zh_CN.UTF-8
[Bambo@revenco-bambo /tmp]
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
More information about the Cygwin
mailing list