如何更改语言环境/编码,以避免在终端中出现奇怪的字符?


9

tree当我从Putty连接到ubuntu盒子并启动时,我已经安装了它tree

$ tree
âââ html.vim -> xml.vim
âââ js.vim -> xml.vim
âââ xml.vim

代替这个:

$ tree --charset=ANSII
|-- html.vim -> xml.vim
|-- js.vim -> xml.vim
`-- xml.vim

例如,当我列出来自npm(的软件包管理器nodejs)的软件包时,我也会遇到此问题

$ npm list
/home/monkey/scripts/chatter
ââ⏠express@3.0.6
â âââ buffer-crc32@0.1.1
â âââ commander@0.6.1
â ââ⏠connect@2.7.2
â â âââ bytes@0.1.0

我该如何更改(从Putty或linux box)?


4
将PuTTY中的字符转换更改为UTF-8。
zxcdw

Answers:


17

将PuTTY中的字符转换更改为UTF-8。


0

油灰菜单> Change Settings...> Category : Window> Translation> Remote Character Set= UTF-8

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.