Maven的依赖安装自己的jar库 [英] Installing own jar library for Maven dependency

查看:143
本文介绍了Maven的依赖安装自己的jar库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这可能是愚蠢的问题,但我还没有找到答案在这里: HTTPS ://github.com/mosabua/maven-android-sdk-deployer (也许我是个盲人)。我想用这个工具来我的图书馆安装到SDK,然后将其加载到<依赖> 在我的的pom.xml 。但我看不到任何说明如何做到这一点。我的藏书httpclientandroidlib-1.1.2.jar。我应该在哪里把它和我应该什么命令加载它通过SDK-部署到SDK?

this may be the stupid question, but I haven't found the answer here : https://github.com/mosabua/maven-android-sdk-deployer (maybe I am blind). I want to use this tool to install my library into sdk and then load it to <dependency> in my POM.xml. But I can't see any instructions how to do this. My library is httpclientandroidlib-1.1.2.jar. Where should I put it and what command should I run to load it to sdk via sdk-deployer ?

我知道我可以使用 Maven的中央,但他们没有我需要的版本。

I know I can use Maven Central, but they don't have the version I need.

推荐答案

如果我明白这个问题正是你不需要Maven的Andr​​oid的SDK-部署。
如果问题是,你需要安装库,这样你可以使用它,你可以使用这样的事情把它添加到你的本地Maven回购

If I understand the question exactly you do not need the maven-android-sdk-deployer. if the issue is that you need to install the library so that you can use it you may add it to your local maven repo using something like this

MVN安装:安装文件-Dfile = / Android的支持 - v4.jar -DgroupId = com.google.android -DartifactId =支持-V4 -Dversion = R12 -Dpackaging = JAR

mvn install:install-file -Dfile=./android-support-v4.jar -DgroupId=com.google.android -DartifactId=support-v4 -Dversion=r12 -Dpackaging=jar

从dir其中的jar

from the dir where the jar is

这是我用过Android的支持-V4,你需要使用合适的groupId等为httpclientandroidlib-1.1.2.jar调整它

this is what I used for android-support-v4, you need to tweak it with the proper groupId etc for the httpclientandroidlib-1.1.2.jar

这篇关于Maven的依赖安装自己的jar库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆