You cannot specify anything but properties, repositories, and
pluginRepositories (IIRC) outside of the POM itself. This is to help
ensure that POMs remain portable.
Rinku wrote:
Hi ,
I am trying to introduce selective dependencies based on profile activation for
a project, but i am encountering an exception (stacktrace below)
<snip>
Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException: Unrecognised tag:
'dependencies' (position: START_TAG seen ...</activation>\r\n
<dependencies>... @12:19)
at
org.apache.maven.profiles.io.xpp3.ProfilesXpp3Reader.parseProfile(ProfilesXpp3Reader.java:577)
at
org.apache.maven.profiles.io.xpp3.ProfilesXpp3Reader.parseProfilesRoot(ProfilesXpp3Reader.java:617)
at
org.apache.maven.profiles.io.xpp3.ProfilesXpp3Reader.read(ProfilesXpp3Reader.java:1126)
at
org.apache.maven.profiles.DefaultMavenProfilesBuilder.buildProfiles(DefaultMavenProfilesBuilder.java:47)
at
org.apache.maven.project.DefaultMavenProjectBuilder.loadProjectExternalProfiles(DefaultMavenProjectBuilder.java:1013)
... 18 more
</snip>
Has any one tried setting up dependencies in Profiles? The profiles.xml that I am using looks as follows:
<profiles>
<profile>
<id>tc-int</id>
<activation>
<property>
<name>target</name>
<value>tc-int</value>
</property>
</activation>
<dependencies>
<dependency>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-core-container-tomcat</artifactId>
</dependency>
</dependencies>
......
</profile>
</profiles>
Am I missing something here? I am referring to the POM descriptor online to create profiles.
Much appreciate pointers and thanks in advance for any!
Cheers,
Rahul
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]