mercredi 29 octobre 2014

Can I add maven dependencies that are packed as anything other than .jar?


Vote count:

0




I just produced my first parent-module project with maven, and successfully installed it. Can I add this project as a dependency in another project, only by referring to the parent? My Eclipse IDE complains that it can't find the parent.jar, but that is not a surprise, as it is packaged as parent.pom.


Question: So is it possible to add a parent (.pom) dependency, and get all transitive dependencies for free, or do I have to add .jar's.


Bonus Question: Is it possible to add dependencies to other packaging formats as well, like a war? I can't really figure out how that would work, or why I would need that at this point though. Just curious.


Disclaimer: I'm still learning maven, and find the philosophy and theory of it to be great. However, there are so many pits and reefs that seems to pop out, and more than once, I struggle to see if I'm trying to do something impossible, or if there is another mistake in configurations I.E. Right now Eclipse says it can't find any of my .m2 referenced dependencies in this one particular project. I have no idea why, as other projects works fine. I am in other words trying to find the error, by checking one area at the time...



asked 2 mins ago







Can I add maven dependencies that are packed as anything other than .jar?

Aucun commentaire:

Enregistrer un commentaire