What are you trying to do? The two profiles looks the same to me (there
might be some minor difference that I didn't spot). I'm quite sure you're
trying to do something the wrong way.

/Anders

On Fri, Aug 27, 2010 at 13:35, Sridhar Laxmipuram Srinivasan <
sridh...@yahoo-inc.com> wrote:

> Yes now the fun part :)
> When I do mvn help:active-profiles -P CommentsBAT,BAT it shows me both are
> active but when I execute it does not execute both, I am completely blank
> here....
>
> [INFO] [help:active-profiles {execution: default-cli}]
> [INFO]
> Active Profiles for Project
> 'com.yahoo.qa.yWsNG.UGCCloud.UGCComments.tests:UGCComments-app:jar:1.0-SNAPSHOT':
>
> The following profiles are active:
>
>  - BAT (source: pom)
>  - CommentsBAT (source: pom)
>
>
> [INFO]
> ------------------------------------------------------------------------
> [INFO] BUILD SUCCESSFUL
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Total time: 1 second
> [INFO] Finished at: Fri Aug 27 11:34:02 GMT 2010
> [INFO] Final Memory: 7M/38M
> [INFO]
> ------------------------------------------------------------------------
>
>
> I do not know what wrong I am doing here
>
>
> Thnkx
> sridharl
>
> -----Original Message-----
> From: anders.g.ham...@gmail.com [mailto:anders.g.ham...@gmail.com] On
> Behalf Of Anders Hammar
> Sent: Friday, August 27, 2010 5:00 PM
> To: Maven Users List
> Subject: Re: Multiple profile execution in maven
>
> It works for me with Maven 2.2.1.
> Try this:
>
> mvn help:active-profiles -P CommentsBAT,BAT
>
> /Anders
>
> On Fri, Aug 27, 2010 at 13:10, Sridhar Laxmipuram Srinivasan <
> sridh...@yahoo-inc.com> wrote:
>
> > I am trying to execute like below:
> >
> > mvn -PCommentsBAT,BAT
> >
> > The above execute CommentsBAT but not BAT
> >
> >
> > My pom is like below:-
> > <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.yahoo.qa.yWsNG.UGCCloud.UGCComments.tests</groupId>
> >  <artifactId>UGCComments-app</artifactId>
> >  <packaging>jar</packaging>
> >  <version>1.0-SNAPSHOT</version>
> >  <name>UGCComments</name>
> >  <url>http://maven.apache.org</url>
> >  <dependencies>
> >    <dependency>
> >                        <groupId>org.testng</groupId>
> >                        <artifactId>testng</artifactId>
> >                        <version>1.0</version>
> >                </dependency>
> > </dependencies
> > <profiles>
> >         <profile>
> >      <id>BAT</id>
> >      <properties>
> >        <comments_artifact></comments_artifact>
> >        </properties>
> >        <activation>
> >      <activeByDefault>false</activeByDefault>
> >      </activation>
> >        <dependencies>
> >       <dependency>
> >      <groupId>Jsonparser</groupId>
> >      <artifactId>Jsonparser</artifactId>
> >      <version>0.1</version>
> >      </dependency>
> >      </dependencies>
> >          <build>
> >     <plugins>
> >      <plugin>
> >         <artifactId>maven-compiler-plugin</artifactId>
> >        <configuration>
> >          <source>1.6</source>
> >          <target>1.6</target>
> >        </configuration>
> >      </plugin>
> >            <plugin>
> >        <groupId>org.apache.maven.plugins</groupId>
> >        <artifactId>maven-surefire-plugin</artifactId>
> >        <version>2.5</version>
> >        <configuration>
> >          <skipTests>false</skipTests>
> >        <argLine>-Xmx512m</argLine>
> >               <suiteXmlFiles>
> >
> > <suiteXmlFile>src/test/resources/CommentsWS.xml</suiteXmlFile>
> >                   <!--
> > <suiteXmlFile>src/test/resources/testng_selng.xml</suiteXmlFile>-->
> >                </suiteXmlFiles>
> >
> >
> <reportsDirectory>${project.build.directory}/Comments1/reports/surefire</reportsDirectory>
> >          <properties>
> >          <properties>
> >
> > <maven.test.failure.ignore>true</maven.test.failure.ignore>
> >         </properties>
> >          <property>
> >                <name>listener</name>
> >
> >
>  
> <value>com.yahoo.test.SelNG.framework.util.MethodSorter,org.uncommons.reportng.HTMLReporter,org.uncommons.reportng.JUnitXMLReporter,
> > com.yahoo.qa.yWsNG.framework.util.report.YWsNGReporter,
> > com.yahoo.test.SelNG.framework.util.TMReporter</value>
> >                        </property>
> >                  </properties>
> >                  <systemProperties>
> >             <property>
> >            <name>apiHost1</name>
> >             <value>${maven.test.apiHost.value}</value>
> >            </property>
> >               <property>
> >                 <name>apiPort1</name>
> >                  <value>${maven.test.apiPort.value}</value>
> >               </property>
> >            </systemProperties>
> >           </configuration>
> >      </plugin>
> >      </plugins>
> >     <testResources>
> >      <testResource>
> >      <directory>src/test/resources</directory>
> >    </testResource>
> >  </testResources>
> >         </build>
> >         </profile>
> > <profile>
> >      <id>CommentsBAT</id>
> >      <properties>
> >        <comments_artifact></comments_artifact>
> >        </properties>
> >        <activation>
> >      <activeByDefault>false</activeByDefault>
> >      </activation>
> >        <dependencies>
> >       <dependency>
> >      <groupId>Jsonparser</groupId>
> >      <artifactId>Jsonparser</artifactId>
> >      <version>0.1</version>
> >      </dependency>
> >      </dependencies>
> >          <build>
> >     <plugins>
> >      <plugin>
> >         <artifactId>maven-compiler-plugin</artifactId>
> >        <configuration>
> >          <source>1.6</source>
> >          <target>1.6</target>
> >        </configuration>
> >      </plugin>
> >            <plugin>
> >        <groupId>org.apache.maven.plugins</groupId>
> >        <artifactId>maven-surefire-plugin</artifactId>
> >        <version>2.5</version>
> >        <configuration>
> >          <skipTests>false</skipTests>
> >        <argLine>-Xmx512m</argLine>
> >               <suiteXmlFiles>
> >
> > <suiteXmlFile>src/test/resources/CommentsWS.xml</suiteXmlFile>
> >                   <!--
> > <suiteXmlFile>src/test/resources/testng_selng.xml</suiteXmlFile>-->
> >                </suiteXmlFiles>
> >
> >
> <reportsDirectory>${project.build.directory}/Comments/reports/surefire</reportsDirectory>
> >          <properties>
> >          <properties>
> >
> > <maven.test.failure.ignore>true</maven.test.failure.ignore>
> >         </properties>
> >          <property>
> >                <name>listener</name>
> >
> >
>  
> <value>com.yahoo.test.SelNG.framework.util.MethodSorter,org.uncommons.reportng.HTMLReporter,org.uncommons.reportng.JUnitXMLReporter,
> > com.yahoo.qa.yWsNG.framework.util.report.YWsNGReporter,
> > com.yahoo.test.SelNG.framework.util.TMReporter</value>
> >                        </property>
> >                  </properties>
> >                  <systemProperties>
> >             <property>
> >            <name>apiHost1</name>
> >             <value>${maven.test.apiHost.value}</value>
> >            </property>
> >               <property>
> >                 <name>apiPort1</name>
> >                  <value>${maven.test.apiPort.value}</value>
> >               </property>
> >            </systemProperties>
> >           </configuration>
> >      </plugin>
> >      </plugins>
> >     <testResources>
> >      <testResource>
> >      <directory>src/test/resources</directory>
> >    </testResource>
> >  </testResources>
> >         </build>
> >         </profile>
> > </profiles>
> > </project>
> >
> >
> >
> >
> > I am trying to run like below:-
> >
> > -----Original Message-----
> > From: anders.g.ham...@gmail.com [mailto:anders.g.ham...@gmail.com] On
> > Behalf Of Anders Hammar
> > Sent: Friday, August 27, 2010 2:44 PM
> > To: Maven Users List
> > Subject: Re: Multiple profile execution in maven
> >
> > Why not the other way around? You clean your pom and send it, and maybe
> > someone can find time to try it out. A complete test project that doesn't
> > work for you, is even better (and thus more likely for someone to try).
> >
> > /Anders
> >
> > On Fri, Aug 27, 2010 at 10:54, Sridhar Laxmipuram Srinivasan <
> > sridh...@yahoo-inc.com> wrote:
> >
> > > Oh is it, If possible can you please share you pom, after removing any
> > > secured/confidential information if any. I need this urgently as I am
> > stuck
> > > on this and wasted lot of time debugging the issue
> > >
> > > Thnkx
> > > sridharl
> > >
> > > -----Original Message-----
> > > From: Jesse Farinacci [mailto:jie...@gmail.com]
> > > Sent: Friday, August 27, 2010 9:15 AM
> > > To: Maven Users List
> > > Subject: Re: Multiple profile execution in maven
> > >
> > > Greetings,
> > >
> > > On Thu, Aug 26, 2010 at 11:29 PM, Sridhar Laxmipuram Srinivasan
> > > <sridh...@yahoo-inc.com> wrote:
> > > > I have tried everything ie with multiple -Ps, comma separated list
> but
> > in
> > > vain :), I think it is a bug, if anybody has any workaround please let
> me
> > > know
> > > >
> > >
> > > $ echo "This worked for me just 2 minutes ago!"
> > > $ mvn -P mysql,deployment package jetty:run-war
> > >
> > > -Jesse
> > >
> > > --
> > > There are 10 types of people in this world, those
> > > that can read binary and those that can not.
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> > > For additional commands, e-mail: users-h...@maven.apache.org
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> > > For additional commands, e-mail: users-h...@maven.apache.org
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> > For additional commands, e-mail: users-h...@maven.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
> For additional commands, e-mail: users-h...@maven.apache.org
>
>

Reply via email to