If you are using eclipse with a maven project and you have errors showing up that are not truly errors, then it is because eclipse is reading your maven.xml file as an ant file.
Eclipse will indentify this file as an ant file due to the .xml extension and the project tag as the root element. You will need to either tell the Ant Editor to ignore errors in the maven.xml files OR associate the maven.xml file with the XML editor instead of the Ant Editor. At the time of this post, there wasn’t an eclipse content type for Maven files (or at last I could not easily find one.)
Here are the options:
Use Ant editor to edit maven.xml files, but turn off the error reporting
- In eclipse, click on Window -> Preferences -> Ant -> Editor
- Click on the Problems tab
- In the first edit box, you can list files that the error reporter will ignore, add maven.xml to this box
Associate the maven.xml file name to the XML content type
- In eclipse, click on Window -> Preferences -> General -> Content Type
- You can know look at your content types and associated extensions, *.xml is listed under ant. You can either change this to be more specific and add the maven.xml to another XML type OR try out your own combinations inside there.
So far no posts