执行mvn package命令时,报以下警告:
File encoding has not been set, using platform encoding GBK
或
编码GBK的不可映射字符
解决方法:
在pom.xml中加入以下内容:
<properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> </properties>