how to change the encoding of the java compilation error message? [closed]

Solution 1:

This is a problem with the default codepage on Windows when you use Terminal.

Use the chcp command at the CMD and PowerShell prompt to list the current code page.

On this page: "Code Page Identifiers - Win32 apps | Microsoft Docs" you will find a list of all Windows code pages. Last on the list is utf-8.

In the Windows 10 version (most current in January 2022) we can configure Regional Settings. Chose the Unicode utf-8 Check-box on Regional Settings of Settings/Regional.