fix: 修复Windows终端UTF-8编码问题,恢复emoji字符

根因: System.out使用平台默认编码(CP936/GBK),emoji无法编码显示为?。
修复方案:
1. JVM参数: -Dstdout.encoding=UTF-8 -Dstderr.encoding=UTF-8 -Dfile.encoding=UTF-8
2. 代码层: PrintStream使用StandardCharsets.UTF_8
3. 启动脚本: run.bat添加chcp 65001, run.ps1设置Console编码

同时revert之前的emoji→ASCII替换,恢复原始emoji符号。

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
liuzh
2026-04-01 20:44:23 +08:00
co-authored by Copilot
parent cc0d3f8b00
commit 549cc79dc6
4 changed files with 11 additions and 2 deletions
+1 -1
View File
@@ -97,7 +97,7 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<jvmArguments>-Xmx512m -Xms256m --enable-native-access=ALL-UNNAMED</jvmArguments>
<jvmArguments>-Xmx512m -Xms256m --enable-native-access=ALL-UNNAMED -Dstdout.encoding=UTF-8 -Dstderr.encoding=UTF-8 -Dfile.encoding=UTF-8</jvmArguments>
</configuration>
</plugin>
<plugin>