When building an old project, sometimes I encounter the dreaded Failed to resolve artifact error.
What I do then is search for the jar and pom of that specific artifact and use the [mvn install:install-file goal to manually install it locally][1].
This solves the trivial case, but sometimes the project's dependency on the artifact is not trivial and includes in the project's pom fields such as:
runtime
or worse:
cglibcglib-nodep
How would you handle these cases? Is there a way to add these fields to the command as well?
[1]: http://maven.apache.org/plugins/maven-install-plugin/usage.html
以上就是Workaround to maven's "Failed to resolve artifact" in non-trivial dependencies的详细内容,更多请关注web前端其它相关文章!