Home >Operation and Maintenance >Linux Operation and Maintenance >How to solve the linux git Chinese garbled problem

How to solve the linux git Chinese garbled problem

藏色散人
藏色散人Original
2021-12-14 14:40:004081browse

linux git中文乱码的解决办法:1、执行“git config --global core.quotepath false”命令;2、手动更改配置文件,编辑内容为“quotepath = false”。

How to solve the linux git Chinese garbled problem

本文操作环境:linux5.9.8系统,Git 2.30.0,Dell G3电脑。

如何解决linux git中文乱码问题?

解决Git在Linux 乱码问题:

在Linux如果要提交的文件名是中文的,默认git commit的时候就会把中文显示为一串数字如下:

 create mode 100644 "\346\265\213\350\257\225"

这个时候只需要添加相应的配置即可显示正常的中文,执行以下命令即可

$ git config --global core.quotepath false

或者手动更改配置文件~/.gitconfig,编辑添加如下内容即可

[core]
    quotepath = false

推荐学习:《linux视频教程

The above is the detailed content of How to solve the linux git Chinese garbled problem. For more information, please follow other related articles on the PHP Chinese website!

Statement:
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