You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Olivier Lamy (JIRA)" <ji...@codehaus.org> on 2006/04/06 15:42:48 UTC

[jira] Created: (MNG-2206) bad properties interpolation with profiles

bad properties interpolation with profiles 
-------------------------------------------

         Key: MNG-2206
         URL: http://jira.codehaus.org/browse/MNG-2206
     Project: Maven 2
        Type: Bug

  Components: Inheritence and Interpolation  
    Versions: 2.0.3    
 Environment: cygwin
    Reporter: Olivier Lamy
    Priority: Blocker
 Attachments: pom.xml

create two profiles in your settings.xml
- id  test with a property <test>dev</test> 
- id snapshots with a property <test>snapshots</test> 

<activeProfiles>
<activeProfile>dev</activeProfile>
<activeProfile>snapshots</activeProfile>
</activeProfiles>

With the attached pom run :
mvn validate :
[echo] dev 
mvn -P snapshots validate :
[echo] dev

Olivier


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Edwin Punzalan (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_66705 ] 

Edwin Punzalan commented on MNG-2206:
-------------------------------------

Olivier,

I tried to reproduce in maven 2.0.4 with my settings xml having:

{code}
  <profiles>
    <profile>
      <id>dev</id>
      <properties>
        <test>dev</test>
      </properties>
    </profile>
    <profile>
      <id>snapshots</id>
      <properties>
        <test>snapshots</test>
      </properties>
    </profile>
  </profiles>
{code}

but I'm not able to reproduce your error.  This may have been fixed in 2.0.4.

Below is what I get:

{code:title=Using mvn -P dev validate}
[INFO] Scanning for projects...
[INFO] -------------------------------------------------------------------------
---
[INFO] Building Maven
[INFO]    task-segment: [validate]
[INFO] -------------------------------------------------------------------------
---
[INFO] [antrun:run {execution: default}]
[INFO] Executing tasks
     [echo] dev
[INFO] Executed tasks
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1 second
[INFO] Finished at: Tue Jun 06 15:35:29 CST 2006
[INFO] Final Memory: 2M/5M
[INFO] ------------------------------------------------------------------------
{code}

{code:title=Using mvn -P snapshots validate}
[INFO] Scanning for projects...
[INFO] -------------------------------------------------------------------------
---
[INFO] Building Maven
[INFO]    task-segment: [validate]
[INFO] -------------------------------------------------------------------------
---
[INFO] [antrun:run {execution: default}]
[INFO] Executing tasks
     [echo] snapshots
[INFO] Executed tasks
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESSFUL
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1 second
[INFO] Finished at: Tue Jun 06 15:35:36 CST 2006
[INFO] Final Memory: 2M/5M
[INFO] ------------------------------------------------------------------------
{code}

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Assignee: Edwin Punzalan
>     Priority: Blocker
>      Fix For: 2.0.5
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "Jason van Zyl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=all ]

Jason van Zyl updated MNG-2206:
-------------------------------

    Fix Version/s:     (was: 2.0.5)
                   2.0.6

> bad properties interpolation with profiles 
> -------------------------------------------
>
>                 Key: MNG-2206
>                 URL: http://jira.codehaus.org/browse/MNG-2206
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Inheritance and Interpolation
>    Affects Versions: 2.0.3
>         Environment: cygwin
>            Reporter: Olivier Lamy
>         Assigned To: Edwin Punzalan
>            Priority: Blocker
>             Fix For: 2.0.6
>
>         Attachments: MNG-2206-maven-project.patch, pom.xml
>
>   Original Estimate: 2 hours
>  Remaining Estimate: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_66706 ] 

Olivier Lamy commented on MNG-2206:
-----------------------------------

Hi,
Have you tried with <id>dev</dev> <activeByDefault>true</activeByDefault>  in settings ?
My problem concerns more the winner profile.
Ok dev is activeByDefault but if I say in the cli -P snapshots, snapshots must win ?
--
Olivier

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Assignee: Edwin Punzalan
>     Priority: Blocker
>      Fix For: 2.0.5
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=all ]

John Casey updated MNG-2206:
----------------------------

    Fix Version: 2.0.5

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Priority: Blocker
>      Fix For: 2.0.5
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_65665 ] 

Olivier Lamy commented on MNG-2206:
-----------------------------------

As I understand there is a random profile activation.
IMO it's a bug, because if I activate a profile with -P cli option this profile must win !.
WDYT ?
Olivier

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Priority: Blocker
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Kenney Westerhof (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_65638 ] 

Kenney Westerhof commented on MNG-2206:
---------------------------------------

I don't see any 'activeByDefault' in the issue description.

If you activate both profiles then currently they're both activated, which is correct.
However, the order in which they're activated is random.

If you activate the 'dev' profile by default, and remove the 'snapshots' profile, then dev is always
activated. If you then specify -Psnapshots it should override the <test> property with the new value 'snapshots'.

But since this is random, the OS/jdk combination determines which one wins.

Is this a correct explanation of the above problem? 

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Priority: Blocker
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "Edwin Punzalan (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=all ]

Edwin Punzalan updated MNG-2206:
--------------------------------

    Remaining Estimate: 2 hours
     Original Estimate: 2 hours

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Assignee: Edwin Punzalan
>     Priority: Blocker
>      Fix For: 2.0.5
>  Attachments: pom.xml
>
> Original Estimate: 2 hours
>         Remaining: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Closed: (MNG-2206) bad properties interpolation with profiles

Posted by "Jason van Zyl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jason van Zyl closed MNG-2206.
------------------------------

      Assignee:     (was: Edwin Punzalan)
    Resolution: Duplicate

Duplicate it appears of not being able to have the command line values set override anything else. 

> bad properties interpolation with profiles 
> -------------------------------------------
>
>                 Key: MNG-2206
>                 URL: http://jira.codehaus.org/browse/MNG-2206
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Inheritance and Interpolation
>    Affects Versions: 2.0.3
>         Environment: cygwin
>            Reporter: Olivier Lamy
>            Priority: Blocker
>             Fix For: 2.0.x
>
>         Attachments: MNG-2206-maven-project.patch, pom.xml
>
>   Original Estimate: 2 hours
>  Remaining Estimate: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_66775 ] 

Olivier Lamy commented on MNG-2206:
-----------------------------------

Oops sorry for this http://jira.codehaus.org/browse/MNG-2346. (I know I have spend few hours on this too ;-) )
The provided test case must be change.
was recorded in http://jira.codehaus.org/browse/MSUREFIRE-89
--
Olivier

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Assignee: Edwin Punzalan
>     Priority: Blocker
>      Fix For: 2.0.5
>  Attachments: MNG-2206-maven-project.patch, pom.xml
>
> Original Estimate: 2 hours
>         Remaining: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "Kenney Westerhof (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=all ]

Kenney Westerhof updated MNG-2206:
----------------------------------

    Fix Version/s:     (was: 2.0.5)
                   2.0.6

> bad properties interpolation with profiles 
> -------------------------------------------
>
>                 Key: MNG-2206
>                 URL: http://jira.codehaus.org/browse/MNG-2206
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Inheritence and Interpolation
>    Affects Versions: 2.0.3
>         Environment: cygwin
>            Reporter: Olivier Lamy
>         Assigned To: Edwin Punzalan
>            Priority: Blocker
>             Fix For: 2.0.6
>
>         Attachments: MNG-2206-maven-project.patch, pom.xml
>
>   Original Estimate: 2 hours
>  Remaining Estimate: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Eric Redmond (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_63032 ] 

Eric Redmond commented on MNG-2206:
-----------------------------------

Firstly, he means to create a profile with id "dev", not "test".

Also, this defect only presents itself if you set an activation of activeByDefault to true.
activeByDefault seems to hold a little too much power here. It does not honor the -P flag.

If you remove "activeByDefault", then snapshot will win, as expected.


> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Priority: Blocker
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_63047 ] 

Olivier Lamy commented on MNG-2206:
-----------------------------------

Sorry for bad entry in the issue.
read id dev with a property <test>dev</test> instead of the previous.
And that's what I have done.
And I have the same result.
But you mean activeByDefault override the profile forced in the cli ??
I have problem with this because i need to declare my company repositories in the default profile.
I'm agree on remove "activeByDefault" : It works on a solaris machine but not on my cygwin (probably a bad configuration of it on my machine I will check).
Thanks,
Olivier


> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Priority: Blocker
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_65662 ] 

Olivier Lamy commented on MNG-2206:
-----------------------------------

Sorry for bad explanation concerning this issue.
I try again ;-).
My pom contains :
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <configuration>
          <tasks>
            <echo>${value}</echo>
          </tasks>        
        </configuration>
        <executions>
          <execution>
            <phase>validate</phase>
            <configuration>
              <tasks>
                <echo>${value}</echo>
              </tasks>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>        
      </plugin>
My settings contains :
- profile <id>dev</dev> <activeByDefault>true</activeByDefault> and in properties section of this profile <value>dev</value>
- profile <id>snapshots</id> and in properties section of this profile <value>snapshots</value>

+ in settings 
	<activeProfiles>
		<activeProfile>dev</activeProfile>
		<activeProfile>snapshots</activeProfile>
	</activeProfiles>

running mvn validate or mvn validate -P snapshots always displays : [echo] dev.
running mvn validate -Dvalue=foo displays well value : [echo] foo
But this doesn't seems to works with the P commands to activate properties values stored in the settings for each profiles.
My use case is the following : I need to store some databases passwords with different profiles (dev,integration, user test and production) and with profile activation with the cli -P, I expect to have a expression replacement.
I hope it's a better explanation ?
Olivier







> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Priority: Blocker
>  Attachments: pom.xml
>
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (MNG-2206) bad properties interpolation with profiles

Posted by "Geoffrey De Smet (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-2206?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_85859 ] 

Geoffrey De Smet commented on MNG-2206:
---------------------------------------

Is my problem of  "cmd line property does not override others" is probably the same issue:


[based on m2.0.5's first rc on the dev list]

I have this profile in my pom.xml:

<profile>
  <id>development</id>
  <activation>
    <activeByDefault>true</activeByDefault>
  </activation>
  <properties>
    <no.daisy.test>true</no.daisy.test>
    <maven.test.skip>${no.daisy.test}</maven.test.skip>
  </properties>
</profile>

So without my settings.xml "mvn install" doesn't run the tests.
But in my settings.xml I have a profile like this:

<profile>
  <id>daisy_1_5</id>
  <properties>
    <no.daisy.test>false</no.daisy.test>
    ...
  </properties>
</profile>

So now "mvn install" does run the tests.

However when I now try
  mvn -Dmaven.test.skip install
The tests are still run,
while I expected my cmd line variable to overwrite my pom.xml and setting.xml properties.


> bad properties interpolation with profiles 
> -------------------------------------------
>
>                 Key: MNG-2206
>                 URL: http://jira.codehaus.org/browse/MNG-2206
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Inheritance and Interpolation
>    Affects Versions: 2.0.3
>         Environment: cygwin
>            Reporter: Olivier Lamy
>         Assigned To: Edwin Punzalan
>            Priority: Blocker
>             Fix For: 2.0.x
>
>         Attachments: MNG-2206-maven-project.patch, pom.xml
>
>   Original Estimate: 2 hours
>  Remaining Estimate: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "Kenney Westerhof (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=all ]

Kenney Westerhof updated MNG-2206:
----------------------------------

    Fix Version/s:     (was: 2.0.6)
                   2.0.5

> bad properties interpolation with profiles 
> -------------------------------------------
>
>                 Key: MNG-2206
>                 URL: http://jira.codehaus.org/browse/MNG-2206
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Inheritence and Interpolation
>    Affects Versions: 2.0.3
>         Environment: cygwin
>            Reporter: Olivier Lamy
>         Assigned To: Edwin Punzalan
>            Priority: Blocker
>             Fix For: 2.0.5
>
>         Attachments: MNG-2206-maven-project.patch, pom.xml
>
>   Original Estimate: 2 hours
>  Remaining Estimate: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brett Porter updated MNG-2206:
------------------------------

    Fix Version/s:     (was: 2.0.x)

> bad properties interpolation with profiles 
> -------------------------------------------
>
>                 Key: MNG-2206
>                 URL: http://jira.codehaus.org/browse/MNG-2206
>             Project: Maven 2
>          Issue Type: Bug
>          Components: Inheritance and Interpolation
>    Affects Versions: 2.0.3
>         Environment: cygwin
>            Reporter: Olivier Lamy
>            Priority: Blocker
>         Attachments: MNG-2206-maven-project.patch, pom.xml
>
>   Original Estimate: 2 hours
>  Remaining Estimate: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MNG-2206) bad properties interpolation with profiles

Posted by "Edwin Punzalan (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-2206?page=all ]

Edwin Punzalan updated MNG-2206:
--------------------------------

    Attachment: MNG-2206-maven-project.patch

> bad properties interpolation with profiles 
> -------------------------------------------
>
>          Key: MNG-2206
>          URL: http://jira.codehaus.org/browse/MNG-2206
>      Project: Maven 2
>         Type: Bug

>   Components: Inheritence and Interpolation
>     Versions: 2.0.3
>  Environment: cygwin
>     Reporter: Olivier Lamy
>     Assignee: Edwin Punzalan
>     Priority: Blocker
>      Fix For: 2.0.5
>  Attachments: MNG-2206-maven-project.patch, pom.xml
>
> Original Estimate: 2 hours
>         Remaining: 2 hours
>
> create two profiles in your settings.xml
> - id  test with a property <test>dev</test> 
> - id snapshots with a property <test>snapshots</test> 
> <activeProfiles>
> <activeProfile>dev</activeProfile>
> <activeProfile>snapshots</activeProfile>
> </activeProfiles>
> With the attached pom run :
> mvn validate :
> [echo] dev 
> mvn -P snapshots validate :
> [echo] dev
> Olivier

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira