How to Set Unicode Encoding in Windows Command Line
If you have a problem see correctly encoding in CLI, here is a solution.
The fact is that the command prompt actually understands these non-english characters, just can’t display them correctly.
I don’t know why my Command Prompt display these garbage, but here is how to resolve it.
Type in:
1 | chcp 65001 |
which will change the code page to UTF-8. You might need to use Lucida console fonts if has character (š) in it.
You can find out more about chcp by using chcp /?
Tips:
The chcp works, I found I have to run it each time when I use the specific command in CLI. This is how to make the changes permanently. I suppose you don’t have to do this if you just want to run a batch file with unicode inside it.
You can change it within the Command Prompt Properties.

