开发者

m2eclipse multiple module projects

I have one parent parent maven project that defines dependencies. Then I have my parent project, which inherits from parent parent project. My parent project has multiple modules each of which has a pom file.

From command line I can just build my parent project and it all works, all my modules compile and build, and even tests pass. But when I create new java project from root of my parent project in eclipse, it never creates Maven Dependencies, and I don't see the jars from the parent parent project. I end up not being able to see any of the jars that my projects use.

I've tried updating project dependencies, I've tried updating project configuration, and n开发者_StackOverflowumerous other cleans, builds etc, but nothing has worked.

Any idea how I might get this to work?

Thanks --MB


In order to work in eclipse, each module needs to be its own project. You will have to add each module to your workspace individually. M2Eclipse should still recognize the parent POMs as long as they are either in your local repository, or at the path specified by the relativePath attribute of the parent group.

If you want to include all of the parent project POMs in your workspace (so you can use the POM editor on them), you can add them as projects, then remove all of the source folders from the Project Build Configuration.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜