[ http://jira.codehaus.org/browse/MNG-4471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=199813#action_199813 ]
j4zzcat edited comment on MNG-4471 at 11/27/09 6:32 PM: -------------------------------------------------------- I can't seem to attach the file, so here's testcase2.xml: {noformat} <?xml version="1.0" encoding="UTF-8"?> <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>testcase2</groupId> <artifactId>testcase2</artifactId> <version>1.0</version> <properties> <test.prop>.</test.prop> </properties> <profiles> <profile> <id>testcase2</id> <activation> <file> <exists>${test.prop}/testcase2.xml</exists> </file> </activation> </profile> <profile> <id>absolute path</id> <activation> <file> <exists>./testcase2.xml</exists> </file> </activation> </profile> </profiles> </project> {noformat} was (Author: j4zzcat): I can't seem to attach the file, so here's testcase2.xml: {noformat} <?xml version="1.0" encoding="UTF-8"?> <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>testcase2</groupId> <artifactId>testcase2</artifactId> <version>1.0</version> <properties> <test.prop>.</test.prop> </properties> <profiles> <profile> <id>testcase2</id> <activation> <file> <exists>${test.prop}/testcase2.xml</exists> </file> </activation> </profile> <profile> <id>absolute path</id> <activation> <file> <exists>./testcase2.xml</exists> </file> </activation> </profile> </profiles> </project> {noformat} > Profile activation fails if <file> contains variables > ------------------------------------------------------ > > Key: MNG-4471 > URL: http://jira.codehaus.org/browse/MNG-4471 > Project: Maven 2 > Issue Type: Bug > Components: Profiles > Affects Versions: 3.0-alpha-5 > Environment: Mac OS X 10.6.2 > Reporter: j4zzcat > Assignee: Benjamin Bentmann > Attachments: pom.xml, testcase.xml, testcase2.xml, testcase2.xml > > > See the attached testcase. > The profile is not activated when <file> has variables in it: > <file><exists>${env.M2_HOME}/bin/mvn</exists></file> > But when the path is absolute, it works: > <file><exists>/my/maven/home/bin/mvn</exists></file> -- 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