开发者

Maven dependency from SVN repository

Using maven 2, is there any way to list a dependency to another maven project which is on a different SVN server but is not on a maven repository?

Ideally, it should be possible to compile and run the main project 开发者_开发知识库without having to manually checkout and build the dependency.


Using maven 2, is there any way to list a dependency to another maven project which is on a different SVN server but is not on a maven repository?

Maven dependencies are always resolved through the local repository and are either downloaded from a remote repository or installed during install. In your case, you'd have to install the mentioned project.

If you want to avoid the manual checkout, you could maybe use svn:externals to extract the other project from the other repository in the same time as the "main" one and setup a reactor build on both.

This should be doable, but is not ideal (and you'll get crazy when the build will fail because of the project that is not under your control). The ideal solution would be to make the other project artifacts available in a remote repository.


AFAIK Maven does not understand how to check things out of SVN.

Of course, you could fall back on embedding Ant targets in your Maven POM ... but that is rather unpleasant.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜