idea通过maven编译项目,控制台打印信息中文乱码

在idea中通过maven对项目进行编译时,控制台的报错中文乱码
maven编译报错信息乱码.png

解决:
File -> Settings -> Build,Execution,Deployment -> Maven -> Runner,在VM Options中加入

-Dfile.encoding=GB2312

配置位置.png

提示信息为中文.png

之前看的很多资料,都说要设置为

-Dfile.encoding=UTF-8

但是设置之后并没有生效。

posted on 2022-08-10 12:50  等茶的茶  阅读(1132)  评论(0编辑  收藏  举报

导航