git总是遇到中文乱码的问题,汇总记录一下解决方案
git status 乱码
解决方法:git config --global core.quotepath false
git commit 乱码
解决方法:git config --global i18n.commitencoding utf-8
git status 乱码
解决方法:git config --global i18n.logoutputencoding utf-8
需要设置环境变量:
Linux系统 export LESSCHARSET=utf-8
Windows系统 set LESSCHARSET=utf-8
或者在系统属性里设置永久的环境变量,不用每次启动终端都设置