1. 下载该jar包到本地(如下载目录结构为:D:\Users\lu.wang\Downloads\searchservice\searchservice\jar\ttd.search.searchservice.jar)
  2. 安装jar到本地maven仓库 cmd中敲入命令:
    mvn install:install-file -Dfile=D:\Users\lu.wang\Downloads\searchservice\searchservice\jar\ttd.search.searchservice.jar -DgroupId=searchservice -DartifactId=searchservice -Dversion=1.0.0 -Dpackaging=jar (-Dfile: 要安装的jar的路径; -DgroupId:pom.xml中的groupId,会生成安装路径; -DartifactId:pom.xml中的artifactId,会生成安装路径; -Dversion:对应pom.xml中的version,jar的版本
  3. 安装成功后,会在本地maven仓库中找到如下路径(如:D:\Users\lu.wang\.m2\repository\searchservice\searchservice)
  4. 在要引用该jar的maven项目的pom.xml里添加该jar依赖
    <dependency>     <groupId>searchservice </groupId>     <artifactId>searchservice </artifactId>     <version>1.0.0</version> </dependency>

相关文章:

  • 2021-11-26
  • 2021-04-28
  • 2022-12-23
  • 2021-09-26
  • 2021-11-20
  • 2022-03-10
  • 2021-12-11
猜你喜欢
  • 2021-05-19
  • 2021-10-26
  • 2021-07-16
  • 2021-07-12
  • 2021-07-10
  • 2022-02-17
相关资源
相似解决方案