1
2
| 为了写这个网站后台,我把项目考在移动硬盘中拿回家继续写,结果maven引用的一个jar在公司maven私服里面,我自己电脑里没有。
项目跑不起来。
|
1
| 机智的我,想起来连接公司服务器,从其他使用到这个jar的项目中获得到了jar包,可是怎么把这个jar安装到本地的maven中,并让我能够在idea中使用呢??
|
1
2
3
4
5
6
7
8
| <dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>version</version>
<scope>system</scope>
<systemPath>d:/mysql-connector.jar</systemPath>
</dependency>
|
1
| 也就是配置一个systemPath标签,值填本地jar包地址,就可以在idea中运行了
|
1
2
3
4
5
6
7
| <plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<includeSystemScope>true</includeSystemScope>
</configuration>
</plugin>
|