Maven导入指定的Jar包
1:在项目下面创建libs文件
2:在pom.xml中引入依赖
<dependency> <groupId>com.XXXX</groupId> <artifactId>XXXX</artifactId> <version>16.8</version> <scope>system</scope> <systemPath>${project.basedir}/libs/xxx.jar</systemPath> </dependency>
3:打包时,需要增加以下配置,红色字体
<build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <configuration> <includeSystemScope>true</includeSystemScope> <classifier>exec</classifier> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-resources-plugin</artifactId> <version>2.4.3</version> </plugin> </plugins> </build>