How to fix Raspberry Pi
中使用 Vim
显示 UTF-8 字符 Emoji
中文乱码
bug All In One
errors
solutions
$ cat /etc/locale.gen$ sudo vim /etc/locale.gen
# 1. 开启 zh_CN.UTF-8 UTF-8, 即去掉开头 # 注释 ✅
zh_CN.UTF-8 UTF-8
# 2. 生成 zh_CN.UTF-8 区域设置 ✅
$ sudo locale-gen
Generating locales (this might take a while)...en_GB.UTF-8... donezh_CN.UTF-8... done
Generation complete.
# 3. 查看
$ locale
LANG=zh_CN.UTF-8
LANGUAGE=
LC_CTYPE="zh_CN.UTF-8"
LC_NUMERIC="zh_CN.UTF-8"
LC_TIME="zh_CN.UTF-8"
LC_COLLATE="zh_CN.UTF-8"
LC_MONETARY="zh_CN.UTF-8"
LC_MESSAGES="zh_CN.UTF-8"
LC_PAPER="zh_CN.UTF-8"
LC_NAME="zh_CN.UTF-8"
LC_ADDRESS="zh_CN.UTF-8"
LC_TELEPHONE="zh_CN.UTF-8"
LC_MEASUREMENT="zh_CN.UTF-8"
LC_IDENTIFICATION="zh_CN.UTF-8"
LC_ALL=zh_CN.UTF-8
# 设置环境变量
$ export LC_ALL="zh_CN.UTF-8"
demos
(🐞 反爬虫测试!打击盗版⚠️)如果你看到这个信息, 说明这是一篇剽窃的文章,请访问 https://www.cnblogs.com/xgqfrms/ 查看原创文章!
refs
https://www.cnblogs.com/xgqfrms/p/17400672.html#5338435
https://www.cnblogs.com/xgqfrms/p/17400672.html#5338436
©xgqfrms 2012-2021
www.cnblogs.com/xgqfrms 发布文章使用:只允许注册用户才可以访问!
原创文章,版权所有©️xgqfrms, 禁止转载 🈲️,侵权必究⚠️!