原文:No plugin found for prefix install in the current project解决方案_一滴水的眼泪-CSDN博客
执行下边命令:
mvn install:install-file -Dfile="D:\ojdbc6.jar" -DgroupId=com.oracle -DartifactId=ojdbc6 -Dversion=11.2.0.3 -Dpackaging=jar
报错:
![](https://img-blog.csdnimg.cn/3f6848778e934d839b306a060a667fea.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBA55yL5a6M6IO95LiN6IO954K56LWe77yf,size_20,color_FFFFFF,t_70,g_se,x_16)
我是在安装ojdbc6.jar时遇到这个错误。
在maven的setting.xml文件中添加
<mirror>
<id>maven2</id>
<mirrorOf>*</mirrorOf>
<name>maven</name>
<url>http://repo1.maven.org/maven2 </url>
</mirror>
然后再执行上边的语句
![](https://img-blog.csdnimg.cn/1b1c80ebbcea425ea8bb9f7609c60cb6.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBA55yL5a6M6IO95LiN6IO954K56LWe77yf,size_20,color_FFFFFF,t_70,g_se,x_16)
另外,有个新方式引入ojdbc6
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc6</artifactId>
<version>${ojdbc6.version}</version>
</dependency>
![](https://img-blog.csdnimg.cn/1d8f59be186041568c802ba919827830.png?x-oss-process=image/watermark,type_d3F5LXplbmhlaQ,shadow_50,text_Q1NETiBA55yL5a6M6IO95LiN6IO954K56LWe77yf,size_20,color_FFFFFF,t_70,g_se,x_16)
这个我这里直接可以下载下来
maven conf settings.xml 中:
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/repositories/central/</url>
<mirrorOf>central</mirrorOf>
</mirror>
<!-- junit镜像地址 -->
<mirror>
<id>junit</id>
<name>junit Address/</name>
<url>http://jcenter.bintray.com/</url>
<mirrorOf>central</mirrorOf>
</mirror>
有需要的可以试试这个。
还有一点需要注意:一定要有外网哦!
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)