Missing Project Properties in Maven Project [message #529088] |
Thu, 22 April 2010 17:38  |
Eclipse User |
|
|
|
Hi,
I am using Galileo.
I am very new to Maven and m2eclipse and I created a multi-module project as per the advice here: http://www.waltercedric.com/java-j2ee-mainmenu-53/361-maven- build-system/1363-maven-multi-module-support-in-m2eclipse.ht ml
The project looks like this in the file system (please excuse all the dashes, can't figure out how to include non-breaking space in post):
ParentProject
|-- pom.xml
|-- ModuleA
----|-- pom.xml
|-- ModuleB
----|-- pom.xml
|-- ModuleC
----|-- pom.xml
In both Package and Project Explorer, they are flattened, like separate projects:
ParentProject
|-- pom.xml
ModuleA
|-- pom.xml
ModuleB
|-- pom.xml
ModuleC
|-- pom.xml
When I bring up the project Properties for any of the "projects", including the "real" parent one, many of the normal menu choices are not displayed, including "Java Build Path".
So, I can't set the build path to use my local repository files and Eclipse can't resolve my imports. This results in my code being covered in red squiggly lines and it's difficult to determine the real compile errors.
I created a single module/normal Maven project and the Properties are available in it.
Does anyone know if this is expected behaviour? Is there a way for me to set my local build path and get rid of the errors?
Thanks in advance!
|
|
|
|
Re: Missing Project Properties in Maven Project [message #529092 is a reply to message #529088] |
Thu, 22 April 2010 18:15  |
Eclipse User |
|
|
|
The solution was to manually update the .project file to inlcude the following:
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
Not sure why they weren't included in the Maven project in the first place or why Java Builder isn't an option to add via Properties.
|
|
|
Powered by
FUDForum. Page generated in 0.06872 seconds