错误提示:
failed: Unable to find a single main class from the following candidates [com.bsj.boyun.open.car.BoyunOpenCarApplication, com.bsj.boyun.open.car.util.BaiduMapstoAutoNaviMapUtil, com.bsj.boyun.open.car.util.BytesUtil, com.bsj.boyun.open.car.util.DateUtils, com.bsj.boyun.open.car.util.DecryptionUtil,
意思是说找不到制定的入口(这些类里面都存在main方法,所以要在maven中制定一个main方法)。
<!--spring boot打包的话需要指定一个唯一的入门-->
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<!-- 指定该Main Class为全局的唯一入口 -->
<mainClass>com.bsj.bluetooth.BluetoothWebApplication</mainClass>
<layout>ZIP</layout>
</configuration>
<executions>
<execution>
<goals>
<goal>repackage</goal><!--可以把依赖的包都打包到生成的Jar包中-->
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>