[forge-issues] [JBoss JIRA] (FORGE-2518) ProfileBuilder does not allow to set a build to set a default build etc
Claus Ibsen (JIRA)
issues at jboss.org
Thu Oct 29 10:39:00 EDT 2015
[ https://issues.jboss.org/browse/FORGE-2518?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13123421#comment-13123421 ]
Claus Ibsen commented on FORGE-2518:
------------------------------------
Thanks yeah I got it working with something similar as above.
> ProfileBuilder does not allow to set a build to set a default build etc
> -----------------------------------------------------------------------
>
> Key: FORGE-2518
> URL: https://issues.jboss.org/browse/FORGE-2518
> Project: Forge
> Issue Type: Enhancement
> Components: Build Tools - Maven
> Affects Versions: 2.20.0.Final
> Reporter: Claus Ibsen
> Labels: api-change
> Fix For: 3.x Future
>
>
> I need to add a maven profile to the maven pom using jboss forge
> {code}
> Profile profile = MavenHelpers.findProfile(pom, "f8-build");
> if (profile == null) {
> //profile = ProfileBuilder.create().setId("f8-build").
> profile = new Profile();
> profile.setId("f8-build");
> Build build = new Build();
> build.setDefaultGoal("clean install docker:build fabric8:json");
> profile.setBuild(build);
> maven.getModel().addProfile(profile);
> }
> {code}
> I tried using the org.jboss.forge.addon.maven.profiles.ProfileBuilder but it does not allow to configure the build where I need to set the default goal.
> The profile should look like
> {code}
> <profile>
> <id>f8-build</id>
> <build>
> <defaultGoal>clean install docker:build fabric8:json</defaultGoal>
> </build>
> </profile>
> {code}
--
This message was sent by Atlassian JIRA
(v6.4.11#64026)
More information about the forge-issues
mailing list