What should I do if vim displays Chinese garbled characters under centos?

王林
Release: 2020-05-18 10:22:12
Original
2692 people have browsed it

What should I do if vim displays Chinese garbled characters under centos?

1. Install the Chinese language pack

# yum -y groupinstall chinese-support
Copy after login

2. Set the corresponding character set

#vi  /etc/sysconfig/i18n
LANG="zh_CN.UTF-8"
Copy after login

or edit the /etc/profile configuration file and add the following One line

export LANG="zh_CN.UTF-8"
Copy after login

3. Make the configuration take effect

# . /etc/profile        
source /etc/profile
Copy after login

4. View the current character set

# echo $LANG
Copy after login

Recommended tutorial: centos tutorial

The above is the detailed content of What should I do if vim displays Chinese garbled characters under centos?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!