You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Muhammad Alsebaey (JIRA)" <ji...@codehaus.org> on 2007/02/25 00:03:15 UTC
[jira] Created: (MNG-2848) Environment variables in profile
activation not working
Environment variables in profile activation not working
-------------------------------------------------------
Key: MNG-2848
URL: http://jira.codehaus.org/browse/MNG-2848
Project: Maven 2
Issue Type: Bug
Components: Profiles
Affects Versions: 2.0.5, 2.0.4
Environment: Windows XP Professional, JDK 1.5
Reporter: Muhammad Alsebaey
When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
I found the same issue on the forums unresolved.
http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
{code:xml}
<profile>
<id>haroon-workstation</id>
<activation>
<property>
<name>env.FOO</name>
<value>foo</value>
</property>
</activation>
.......
</profile>
{code}
--
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-2848) Environment variables in profile
activation not working
Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brett Porter updated MNG-2848:
------------------------------
Fix Version/s: (was: 2.1-alpha-1)
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: Vincent Siveton
> Fix For: 2.0.9
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "k (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_106080 ]
k commented on MNG-2848:
------------------------
Has there been any resolution to this issue? I am currently also trying to access environment variables from within <profile> (be it within profiles.xml and pom.xml) with no success. Outside of <profile>, I can access environment variables just fine, but within <profile>, using the environment variable as an activation property, does not seem to work.
I've been unsuccessful trying to access the variable using the following methods within <profile>:
env.FOO
FOO
${env.FOO}
${FOO}
Any information reguarding this issue would be greatly appreciated... especially since this has been an issue for well over a year now (referring to http://jira.codehaus.org/browse/MNG-2276 ).
Defining the variable via the commandline interface does work however, as stated in the link above.
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Fix For: Reviewed Pending Version Assignment
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
John Casey closed MNG-2848.
---------------------------
Assignee: John Casey (was: Vincent Siveton)
Resolution: Fixed
Looks like the system-property-setting has been reinstated, and the execution properties are still setup and used internally as specified in the patch. This is probably the best we can expect for now, unless/until we find a way to control the way plugins use (and more importantly, pass on to their delegates) the system properties.
I'm closing this issue. We can open a new one later if we need to fine-tune this behavior further.
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: John Casey
> Fix For: 2.0.9
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "Vincent Siveton (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Vincent Siveton closed MNG-2848.
--------------------------------
Assignee: Vincent Siveton
Resolution: Fixed
Fix Version/s: (was: Reviewed Pending Version Assignment)
2.1-alpha-1
2.0.9
Patch applied in r609944. Thanks!
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: Vincent Siveton
> Fix For: 2.0.9, 2.1-alpha-1
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "Brian Fox (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_125928 ]
Brian Fox commented on MNG-2848:
--------------------------------
vincent: any way to get this for 2.0.9 this week?
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: Vincent Siveton
> Fix For: 2.0.9
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "Richard van der Hoff (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_119616 ]
Richard van der Hoff commented on MNG-2848:
-------------------------------------------
Oops, this seems to have broken property passing in mvn exec:java - see MEXEC-41
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: Vincent Siveton
> Fix For: 2.0.9, 2.1-alpha-1
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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] Reopened: (MNG-2848) Environment variables in profile
activation not working
Posted by "Vincent Siveton (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Vincent Siveton reopened MNG-2848:
----------------------------------
To reinvestigate due to Richard's comment
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: Vincent Siveton
> Fix For: 2.0.9, 2.1-alpha-1
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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] Issue Comment Edited: (MNG-2848) Environment variables in
profile activation not working
Posted by "k (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_106080 ]
k edited comment on MNG-2848 at 8/31/07 9:08 AM:
-------------------------------------------------
Has there been any resolution to this issue? I am currently also trying to access environment variables from within <profile> (be it within profiles.xml and pom.xml) with no success. Outside of <profile>, I can access environment variables just fine, but within <profile>, using the environment variable as an activation property, does not seem to work.
I've been unsuccessful trying to access the variable using the following methods within <profile>:
env.FOO
FOO
${env.FOO}
${FOO}
Any information reguarding this issue would be greatly appreciated... especially since this has been an issue for well over a year now (referring to http://jira.codehaus.org/browse/MNG-2276 ).
Defining the variable via the commandline interface does work however, as stated in the link above.
Btw, my version of maven is 2.0.7
was:
Has there been any resolution to this issue? I am currently also trying to access environment variables from within <profile> (be it within profiles.xml and pom.xml) with no success. Outside of <profile>, I can access environment variables just fine, but within <profile>, using the environment variable as an activation property, does not seem to work.
I've been unsuccessful trying to access the variable using the following methods within <profile>:
env.FOO
FOO
${env.FOO}
${FOO}
Any information reguarding this issue would be greatly appreciated... especially since this has been an issue for well over a year now (referring to http://jira.codehaus.org/browse/MNG-2276 ).
Defining the variable via the commandline interface does work however, as stated in the link above.
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Fix For: Reviewed Pending Version Assignment
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "Richard van der Hoff (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_126987 ]
Richard van der Hoff commented on MNG-2848:
-------------------------------------------
Yes, agreed that this seems the most sensible approach for now.
Thanks for sorting this, guys.
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Assignee: John Casey
> Fix For: 2.0.9
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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-2848) Environment variables in profile
activation not working
Posted by "Richard van der Hoff (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2848?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Richard van der Hoff updated MNG-2848:
--------------------------------------
Attachment: MNG-2848.patch
Here's a patch, against maven-core 2.0.8, which makes profile activation via environment variables work.
> Environment variables in profile activation not working
> -------------------------------------------------------
>
> Key: MNG-2848
> URL: http://jira.codehaus.org/browse/MNG-2848
> Project: Maven 2
> Issue Type: Bug
> Components: Profiles
> Affects Versions: 2.0.4, 2.0.5
> Environment: Windows XP Professional, JDK 1.5
> Reporter: Muhammad Alsebaey
> Fix For: Reviewed Pending Version Assignment
>
> Attachments: MNG-2848.patch
>
>
> When using an environment variable as a profile activation variable, it doesnt work, using either env.X or ${env.X} doesnt work.
> I found the same issue on the forums unresolved.
> http://www.nabble.com/profile-activation-based-on-environment-variables-tf2585492s177.html#a7208580
> Basically, the following doesnt work, where FOO is a windows environment variable (like PATH for example) :
> {code:xml}
> <profile>
> <id>haroon-workstation</id>
> <activation>
> <property>
> <name>env.FOO</name>
> <value>foo</value>
> </property>
> </activation>
> .......
> </profile>
> {code}
--
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