问题:
创建maven项目时,Dependencies中没有org.mybatis.spring.boot这项依赖,导致pom.xml文件导入mybatis时爆红
第一次创建maven项目,有很多不了解的地方,欢迎任何big old有任何见解。小弟有礼了。
浏览了很多篇文章,都没有介绍如何在dependencies中引入mybatis这项依赖,最终误打误撞成功引入,具体步骤如下:
步骤过程
跟着很多文章尝试了很多次,最开始修改镜像,然后编译maven,不行
<localRepository>/Users/ceramj/.m2/repository</localRepository>
<mirrors>
<!-- mirror
| Specifies a repository mirror site to use instead of a given repository. The repository that
| this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used
| for inheritance and direct lookup purposes, and must be unique across the set of mirrors.
|
-->
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>
<mirror>
<id>jboss</id>
<name>jboss</name>
<url>https://repository.jboss.org/nexus/content/repositories/releases/</url>
<mirrorOf>JBoss Releases</mirrorOf>
</mirror>
</mirrors>
然后重新在plugin中点击install:install 也不行。
最后实在没办法误打误撞,直接在
1、pom.xml文件中把坐标打出来,
2、然后重新编译maven,
3、问题就解决了。