进入git安装目录,通常是C:\Program Files\Git\
1 编辑或者创建etc\gitconfig文件,在文件末尾增加以下内容:
[gui]
encoding = utf-
8
[i18n]
commitencoding = utf-
8
[svn]
pathnameencoding = utf-
8
2 编辑etc\git-completion.bash文件,在文件末尾增加以下内容:
alias ls=
'ls --show-control-chars --color=auto'
3 编辑etc\inputrc文件,修改output-meta和convert-meta属性值:
set output-meta on
set convert-meta off
4 编辑profile文件,在文件末尾添加如下内容:
export LESSHARESET=utf-
8
5 在git bash 中右键找到text选项 设置编码为utf -8,如图:
转载请注明原文地址: https://ju.6miu.com/read-6019.html