T
timasmith
It appears mavens site builder doesnt read my pom.xml - though all the
other utilities (compiles, package, filter etc.) are fine. It *is*
valid XML (pom.xml follows stacktrace)
C:\myproject\build\registration>mvn site
[INFO] Scanning for projects...
[INFO]
-------------------------------------------------------------------------
---
[ERROR] FATAL ERROR
[INFO]
-------------------------------------------------------------------------
---
[INFO] Error building POM (may not be this project's POM).
Project ID: unknown
POM Location: C:\myproject\build\registration\pom.xml
Reason: Parse error reading POM. Reason: parser must be on START_TAG or
TEXT to
read text (position: START_TAG seen ...<resources>\r\n
<filters><filter>... @
31:22)
[INFO]
-------------------------------------------------------------------------
---
[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Parse error reading
POM. Reaso
n: parser must be on START_TAG or TEXT to read text (position:
START_TAG seen ..
..<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:365)
at
org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:278)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:249)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.project.InvalidProjectModelException: Parse
error re
ading POM. Reason: parser must be on START_TAG or TEXT to read text
(position: S
TART_TAG seen ...<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1134)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1094)
at
org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFi
le(DefaultMavenProjectBuilder.java:289)
at
org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMave
nProjectBuilder.java:274)
at
org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:515)
at
org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:447)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:351)
... 11 more
Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException:
parser must
be on START_TAG or TEXT to read text (position: START_TAG seen
....<resources>\r
\n <filters><filter>... @31:22)
at
org.codehaus.plexus.util.xml.pull.MXParser.nextText(MXParser.java:106
8)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseBuild(MavenXpp3Re
ader.java:682)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Re
ader.java:2284)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.j
ava:4548)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1130)
... 17 more
[INFO]
-------------------------------------------------------------------------
---
[INFO] Total time: < 1 second
[INFO] Finished at: Sat Jul 08 14:15:44 EDT 2006
[INFO] Final Memory: 1M/2M
[INFO]
-------------------------------------------------------------------------
---
C:\myproject\build\registration>mvn -version
Maven version: 2.0.2
C:\myproject\build\registration>mvn -e site
+ Error stacktraces are turned on.
[INFO] Scanning for projects...
[INFO]
-------------------------------------------------------------------------
---
[ERROR] FATAL ERROR
[INFO]
-------------------------------------------------------------------------
---
[INFO] Error building POM (may not be this project's POM).
Project ID: unknown
POM Location: C:\myproject\build\registration\pom.xml
Reason: Parse error reading POM. Reason: parser must be on START_TAG or
TEXT to
read text (position: START_TAG seen ...<resources>\r\n
<filters><filter>... @
31:22)
[INFO]
-------------------------------------------------------------------------
---
[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Parse error reading
POM. Reaso
n: parser must be on START_TAG or TEXT to read text (position:
START_TAG seen ..
..<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:365)
at
org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:278)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:249)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.project.InvalidProjectModelException: Parse
error re
ading POM. Reason: parser must be on START_TAG or TEXT to read text
(position: S
TART_TAG seen ...<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1134)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1094)
at
org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFi
le(DefaultMavenProjectBuilder.java:289)
at
org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMave
nProjectBuilder.java:274)
at
org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:515)
at
org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:447)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:351)
... 11 more
Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException:
parser must
be on START_TAG or TEXT to read text (position: START_TAG seen
....<resources>\r
\n <filters><filter>... @31:22)
at
org.codehaus.plexus.util.xml.pull.MXParser.nextText(MXParser.java:106
8)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseBuild(MavenXpp3Re
ader.java:682)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Re
ader.java:2284)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.j
ava:4548)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1130)
... 17 more
[INFO]
-------------------------------------------------------------------------
---
[INFO] Total time: < 1 second
[INFO] Finished at: Sat Jul 08 14:22:03 EDT 2006
[INFO] Final Memory: 1M/2M
[INFO]
-------------------------------------------------------------------------
---
C:\myproject\build\registration>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.myproject.registration</groupId>
<artifactId>myproject-registration-1.0.jar</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>Patient Information System</name>
<url>http://www.myproject.com</url>
<description>Patient Information System</description>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
</plugins>
<resources>
<filters><filter>filter.properties</filter></filters>
<resource><directory>src/main/resources</directory>
<filtering>true</filtering></resource>
</resources>
</build>
</project>
other utilities (compiles, package, filter etc.) are fine. It *is*
valid XML (pom.xml follows stacktrace)
C:\myproject\build\registration>mvn site
[INFO] Scanning for projects...
[INFO]
-------------------------------------------------------------------------
---
[ERROR] FATAL ERROR
[INFO]
-------------------------------------------------------------------------
---
[INFO] Error building POM (may not be this project's POM).
Project ID: unknown
POM Location: C:\myproject\build\registration\pom.xml
Reason: Parse error reading POM. Reason: parser must be on START_TAG or
TEXT to
read text (position: START_TAG seen ...<resources>\r\n
<filters><filter>... @
31:22)
[INFO]
-------------------------------------------------------------------------
---
[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Parse error reading
POM. Reaso
n: parser must be on START_TAG or TEXT to read text (position:
START_TAG seen ..
..<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:365)
at
org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:278)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:249)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.project.InvalidProjectModelException: Parse
error re
ading POM. Reason: parser must be on START_TAG or TEXT to read text
(position: S
TART_TAG seen ...<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1134)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1094)
at
org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFi
le(DefaultMavenProjectBuilder.java:289)
at
org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMave
nProjectBuilder.java:274)
at
org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:515)
at
org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:447)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:351)
... 11 more
Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException:
parser must
be on START_TAG or TEXT to read text (position: START_TAG seen
....<resources>\r
\n <filters><filter>... @31:22)
at
org.codehaus.plexus.util.xml.pull.MXParser.nextText(MXParser.java:106
8)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseBuild(MavenXpp3Re
ader.java:682)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Re
ader.java:2284)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.j
ava:4548)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1130)
... 17 more
[INFO]
-------------------------------------------------------------------------
---
[INFO] Total time: < 1 second
[INFO] Finished at: Sat Jul 08 14:15:44 EDT 2006
[INFO] Final Memory: 1M/2M
[INFO]
-------------------------------------------------------------------------
---
C:\myproject\build\registration>mvn -version
Maven version: 2.0.2
C:\myproject\build\registration>mvn -e site
+ Error stacktraces are turned on.
[INFO] Scanning for projects...
[INFO]
-------------------------------------------------------------------------
---
[ERROR] FATAL ERROR
[INFO]
-------------------------------------------------------------------------
---
[INFO] Error building POM (may not be this project's POM).
Project ID: unknown
POM Location: C:\myproject\build\registration\pom.xml
Reason: Parse error reading POM. Reason: parser must be on START_TAG or
TEXT to
read text (position: START_TAG seen ...<resources>\r\n
<filters><filter>... @
31:22)
[INFO]
-------------------------------------------------------------------------
---
[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Parse error reading
POM. Reaso
n: parser must be on START_TAG or TEXT to read text (position:
START_TAG seen ..
..<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:365)
at
org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:278)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:249)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.project.InvalidProjectModelException: Parse
error re
ading POM. Reason: parser must be on START_TAG or TEXT to read text
(position: S
TART_TAG seen ...<resources>\r\n <filters><filter>... @31:22)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1134)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1094)
at
org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFi
le(DefaultMavenProjectBuilder.java:289)
at
org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMave
nProjectBuilder.java:274)
at
org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:515)
at
org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:447)
at
org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:351)
... 11 more
Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException:
parser must
be on START_TAG or TEXT to read text (position: START_TAG seen
....<resources>\r
\n <filters><filter>... @31:22)
at
org.codehaus.plexus.util.xml.pull.MXParser.nextText(MXParser.java:106
8)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseBuild(MavenXpp3Re
ader.java:682)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Re
ader.java:2284)
at
org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.j
ava:4548)
at
org.apache.maven.project.DefaultMavenProjectBuilder.readModel(Default
MavenProjectBuilder.java:1130)
... 17 more
[INFO]
-------------------------------------------------------------------------
---
[INFO] Total time: < 1 second
[INFO] Finished at: Sat Jul 08 14:22:03 EDT 2006
[INFO] Final Memory: 1M/2M
[INFO]
-------------------------------------------------------------------------
---
C:\myproject\build\registration>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.myproject.registration</groupId>
<artifactId>myproject-registration-1.0.jar</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>Patient Information System</name>
<url>http://www.myproject.com</url>
<description>Patient Information System</description>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
</plugins>
<resources>
<filters><filter>filter.properties</filter></filters>
<resource><directory>src/main/resources</directory>
<filtering>true</filtering></resource>
</resources>
</build>
</project>