springboot打包包含lib文件夹的jar包

怼烎@ 2022-03-19 01:28 719阅读 0赞

1、添加dependency

  1. <dependency>
  2. <groupId>com.tyilack</groupId>
  3. <artifactId>test</artifactId>
  4. <version>4.4</version>
  5. <scope>system</scope>
  6. <systemPath>${project.basedir}/lib/test-4.4.jar</systemPath>
  7. </dependency>

2、原有plugin中天下configuration

  1. <includeSystemScope>true</includeSystemScope>
  2. <plugin>
  3. <groupId>org.springframework.boot</groupId>
  4. <artifactId>spring-boot-maven-plugin</artifactId>
  5. <configuration>
  6. <includeSystemScope>true</includeSystemScope>
  7. <mainClass>com.tyilack.assist.App</mainClass>
  8. </configuration>
  9. <executions>
  10. <execution>
  11. <goals>
  12. <goal>repackage</goal>
  13. </goals>
  14. </execution>
  15. </executions>
  16. </plugin>

发表评论

表情:
评论列表 (有 0 条评论,719人围观)

还没有评论,来说两句吧...

相关阅读