macos maven package runs Chinese garbled
use mvn clean install
on macos to pack the jar package, and then run the jar package on the linux server, but the log is garbled in Chinese, so it"s OK to pack it on windows as well.
jar package I uploaded to the server through iTerm2 using the scp command.
it"s not clear which piece went wrong.
my attempt
at first, I thought it was the configuration of pom.xml, then add the encoding configuration to pom.xml, as follows:
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<maven.compiler.encoding>UTF-8</maven.compiler.encoding>
then run on linux again, the Chinese is still garbled.
the same jar package runs directly on macos without garbled code.
ask for help
what is the cause of the above problems? How to solve it?