My rule for projects built using Maven is "if it doesn't build using mvn from the command line, then the build is broken."
If code is added to the project which requires a dependency, and a corresponding pom.xml modification is not added along with it, your project will fail to build. So I would say the developer who added code without a corresponding update of pom.xml "broke the build". Even if it builds in Eclipse on their machine etc, unless it builds from the command line, its broken. So they would need to coordinate with the maintainer to get the proper jars added to the repository and pom.xml, and only THEN check in the code which utilizes those new dependencies. Wayne On 11/17/06, jiangshachina <[EMAIL PROTECTED]> wrote:
Hi guys, When use Maven for building project, we must need local repository. But what about on developing time? For example, I'm developing a complex Web application. When the project started, I set many dependencies in pom.xml, and use eclipse:eclipse to make Eclipse project descriptor files.The dependencies are set in Eclipse Java Build Path. But I don't set all dependencies at the beginning(maybe "mission impossible"), other jars would be added to pom.xml as dependency in the future. Now, my question is "how do I add the jars to Eclipse Java Build Path". I think there are two ways: [1]via M2_REPO, use the jars in local repository. [2]assembly the jars in one directory, and add them to build path directory. Generally, which one is better? May some friends puzzle that why the question released? In fact, the project is developed by several co-workers, different persons may use different jars. And only one maintains the pom files and repository. Some one need some jars, and he/she has had them, then he/she would add jars to build path directly(way [2]), then advice the maintainer to add the jars to dependencies and update repository. I think the approach is dangerous. Because one's jars may not synchronous with corresponding artifacts(especially version) in repository. I want know how to deal with the matter in your organization. Thanks! a cup of Java, cheers! Sha Jiang -- View this message in context: http://www.nabble.com/Use-jars-in-local-repo-or-other-dirs--tf2658390s177.html#a7415269 Sent from the Maven - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
