在pom.xml文件中加入

<plugin>

<groupId>org.apache.maven.plugins</groupId>

<artifactId>maven-war-plugin</artifactId>

<version>3.2.0</version>

</plugin>

但我们进行jar打包时出现了Cannot access defaults field of Properties,原因就是因为

 在pom.xml中的packageing是设置打包类型的可以是war也可以是jar

更多推荐

maven打包时出现了Cannot access defaults field of Properties