maven打包编译出现File encoding has not been set

idea中,maven在执行complie打包编译时,后台输出警告信息

[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
查询了许久发现,pom.xml文件中增加一个配置项即可

 <properties>
        <project.build.sourceEncoding>UTF-8project.build.sourceEncoding>
   properties>

你可能感兴趣的:(错误记录,java,maven)