实际项目中pom.xml依赖写法:

  

 <dependency>  
    <groupId>org.springframework</groupId>  
    <artifactId>spring-context-support</artifactId>  
    <version>3.1.0.RELEASE</version>  
</dependency>  

 

Maven 安装 JAR 包的命令是:

   

mvn install:install-file   
-Dfile=jar包的位置   
-DgroupId=上面的groupId   
-DartifactId=上面的artifactId   
-Dversion=上面的version   
-Dpackaging=jar  

 

例如我的这个spring-context-support-3.1.0.RELEASE.jar 文件放在了"D:\mvn\"中

则命令为(在cmd中执行):

mvn install:install-file -Dfile=D:\mvn\spring-context-support-3.1.0.RELEASE.jar 

-DgroupId=org.springframework  -DartifactId=spring-context-support  -Dversion=3.1.0.RELEASE  -Dpackaging=jar

注意:路径和名称中不要有空格和中文,命令为一行,不要换行

相关文章:

  • 2022-12-23
  • 2021-09-28
  • 2021-07-05
  • 2021-04-25
  • 2021-04-11
  • 2022-12-23
  • 2021-07-08
猜你喜欢
  • 2022-01-24
  • 2021-06-16
  • 2022-12-23
  • 2021-05-24
  • 2021-04-28
  • 2022-12-23
相关资源
相似解决方案