NetBeans Forums
| View previous topic :: View next topic |
| Author |
Message |
vhusainov
Joined: 30 Jul 2009 Posts: 2
|
Posted: Thu Jul 30, 2009 7:01 am Post subject: Maven profile activation |
|
|
I've got multimodule maven project. Depending on profile I've got different dependencies (or some dependencies may become optional).
I've found out that the only way to activate profile of dependency with it's own dependencies is to specify the some activation property for profile. So when I'm using just plain maven I can switch full stack of dependencies using some environment property.
But when I'm using netbeans I couldn't find a way to specify some environment property to show in dependency list only dependencies of activated profiles. If I specify it in Actions properties of project netbeans builds everithing fine.
Is there any way to activate profiles in netbeans using activation properties to show correct dependency list in project view? |
|
| Back to top |
|
 |
mkleint Posted via mailing list.
|
Posted: Thu Jul 30, 2009 9:25 am Post subject: Maven profile activation |
|
|
vhusainov wrote:
| Quote: | I've got multimodule maven project. Depending on profile I've got different dependencies (or some dependencies may become optional).
I've found out that the only way to activate profile of dependency with it's own dependencies is to specify the some activation property for profile. So when I'm using just plain maven I can switch full stack of dependencies using some environment property.
But when I'm using netbeans I couldn't find a way to specify some environment property to show in dependency list only dependencies of activated profiles. If I specify it in Actions properties of project netbeans builds everithing fine.
Is there any way to activate profiles in netbeans using activation properties to show correct dependency list in project view?
| not directly from the UI, you can use the profiles.xml files (next to
the pom.xml file) that can contain your properties and other activation
logic, even explicit activation.
in the ui it's not possible to distinguish what dependencies came from
which profile. We get a complete resolved MavenProject instance that
doesn't keep track of profile states..
Milos
|
|
| Back to top |
|
 |
vhusainov
Joined: 30 Jul 2009 Posts: 2
|
Posted: Thu Jul 30, 2009 10:51 am Post subject: |
|
|
As I understand, profiles get activated by environment properties, not by properties in profiles. Even when I declare property in profiles.xml, maven don't build correct dependencies. Only environment property activates profile of project and of dependencies.
Anyway I've tried to open project with activated profile (with property specified) in netbeans and it also don't get correct dependencies |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|