SpringBoot,打包SpringBoot程序后,在cmd运行出现了 某某某.jar中没有注清单属性 。
我的解决方案:
对pom.xml文件做如下修改
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
<encoding>UTF-8</encoding>
</configuration>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>${spring-boot.version}</version>
<!-- 把这里给删除就可以打包成功 -->
<!--<configuration>
<mainClass>com.sun.SSMPApplication</mainClass>
<skip>true</skip>
</configuration>-->
<executions>
<execution>
<id>repackage</id>
<goals>
<goal>repackage</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>