1<plugin> 2 <groupId>org.springframework.boot</groupId> 3 <artifactId>spring-boot-maven-plugin</artifactId> 4 <configuration> 5 <executable>true</executable> 6 </configuration> 7</plugin>
加入<executable>true</executable>就可以让编程出来的jar不需要java -jar就可以直接运行。