Git bash Chinese mosaic

when git bash executes the command, the Chinese prompt is not displayed, and it is not garbled, as shown in the figure.
option whether zh-CN, UTF-8 is set or useless

Feb.27,2021

clipboard.png
try


set to GBK instead of utf-8


this is the garbled code caused by coding problems. You try several compatible Chinese codes one by one:
utf-8 (not needed), gbk, gb2312, ansi, iso8859-1, etc.


windows. Windows's command uses gbk coding. If you use git bash's command directly, there will be no garbled code. It is strongly not recommended to change the code indiscriminately. You will find that your git commit is all garbled

.
Menu