去除[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i
去除[WARNING] Using platform encoding (GBK actually) to copy filtered resources, i.e. build is platform dependent!
再使用maven和jetty的时候,如果你不想看到上面的警告,那么你只需要修改pom如下:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>2.3</version>
<configuration>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
添加<configuration>…</configuration>即可
maven打包时始终出现E:\shuospace\trip\src\main\java\com\coheg\trip\web\TripApplyAction.java:[267,6]-source 1.3中不支持泛型(请使用-source 5或更高版本以启用泛型)Map<String, Object> map = new HashMap<String, Object>();
在pom.xml文件中加入下一面一段语句来指定所用的版本,尽管在eclipse中配置了正确的“Build Path”:
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<target>1.5</target>
<source>1.5</source>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
</plugins>
</build>
重新运行mvn clean eclipse:eclipse -Dmaven.test.skip=true,接着mvn package,问题解决。