---
title: "本地仓库安装已有JAR包"
author: "zzmt2012"
date: "2015-06-13T23:12:19Z"
tags: []
categories: ["研发管理"]
slug: "jar"
draft: false
lastmod: "2015-07-11T22:25:43Z"
id: 2219499
url: "https://zzmt2012.iteye.com/blog/2219499"
---

下面的命令可以在本地仓库中安装一个已有的JAR：

mvn install:install-file -Dfile="F:\工作软件\axis-1.4.jar" -DgroupId="org.apache.axis" -DartifactId="axis" -Dversion="1.4" -Dpackaging=jar

mvn install:install-file -Dfile="F:\工作软件\commons-httpclient-3.1.jar" -DgroupId="commons-httpclient" -DartifactId="commons-httpclient" -Dversion="3.1" -Dpackaging=jar