[ 
https://jira.codehaus.org/browse/MRELEASE-614?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Robert Scholte closed MRELEASE-614.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: 2.4
         Assignee: Robert Scholte

Should be fixed with MRELEASE-571
                
> releaseProfiles works only if at least one (default) profile is activated in 
> the same pom.xml
> ---------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-614
>                 URL: https://jira.codehaus.org/browse/MRELEASE-614
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: perform
>    Affects Versions: 2.0
>         Environment: WindowsXP, Maven-2.2.1
>            Reporter: Torsten Reinhard
>            Assignee: Robert Scholte
>             Fix For: 2.4
>
>
> related to MRELEASE-459 I decided to define an empty "dummy" profile, which 
> is activated by default instead of passing -P... at the command line at mvn 
> release:perform.
> I´ve put this into our company parent pom.xml, next to the release profile 
> that might be enabled during mvn release:perform:
> {code:xml}
> <profiles>
>       <!-- default profile is needed, because otherwise mvn release:perform 
> will not activate the release profile -->
>       <!-- see http://jira.codehaus.org/browse/MRELEASE-459 for details-->
>       <profile>                       
>               <id>dummy</id>
>               <activation>
>                       <activeByDefault>true</activeByDefault>
>               </activation>
>       </profile>
>               
>       <profile>                       
>               <id>release</id>
>               <properties>
>                       <!-- could be used at mvn release:perform -->
>                       <!-- will set productVersion to the current 
> (released)project.scm.tag -->
>                       <productVersion>${project.scm.tag}</productVersion>     
>         
>               </properties>
>       </profile>
> {code}
> Than, in one child module I configured the maven-release-plugin as:
> {code:xml}
>       <configuration>
>               
> <workingDirectory>c:\LocalViewsRelease\${project.artifactId}-${project.version}</workingDirectory>
>               <preparationGoals>clean install</preparationGoals>
>               <releaseProfiles>release</releaseProfiles>
>       </configuration>        
> {code}
> => this should activate the dummy profile (which is activated by default) and 
> the release profile - but it does NOT !
> {noformat}
> [DEBUG] Executing: cmd.exe /X /C "C:\eap\apache-maven-2.2.1\bin\mvn.bat -X -D 
> maven.repo.local=D:\mavenrepo -D performRelease=true deploy site-deploy"
> {noformat}
> I could only get this to work copying the dummy profile again into the child 
> {{pom.xml}}.
> {noformat}
> [DEBUG] Executing: cmd.exe /X /C "C:\eap\apache-maven-2.2.1\bin\mvn.bat -X -D 
> maven.repo.local=D:\mavenrepo -D performRelease=true -P dummy,release deploy 
> site-deploy"
> {noformat}
> The fix should:
> - fix MRELEASE-459 first, so no more default profile is needed to get 
> releaseProfiles to work
> - fix the inheritance of (default) profiles during {{mvn release:perform}}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to