You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/05/28 12:55:13 UTC

[jira] [Commented] (MNG-5863) default pom's release-profile should invoke source plugin with goal "jar-no-fork" instead of "jar"

    [ https://issues.apache.org/jira/browse/MNG-5863?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15305336#comment-15305336 ] 

ASF GitHub Bot commented on MNG-5863:
-------------------------------------

GitHub user pkozelka reopened a pull request:

    https://github.com/apache/maven/pull/61

    fix release profile to use source:jar-no-fork instead of source:jar

    This fixes `release-profile` in Maven's default pom so that it invokes `source:jar-no-fork` instead of `source:jar`, because the forked build can sometimes make troubles.
    
    More details are in jira: [MNG-5863](https://issues.apache.org/jira/browse/MNG-5863).

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/pkozelka/maven pk/fix-release-profile

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/maven/pull/61.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #61
    
----
commit 85d894443c69be1894d3b0b8f3680447bf58457f
Author: Petr Kozelka <pk...@gmail.com>
Date:   2015-07-23T15:14:32Z

    [MNG-5863] fix release profile to use source:jar-no-fork instead of source:jar

----


> default pom's release-profile should invoke source plugin with goal "jar-no-fork" instead of "jar"
> --------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5863
>                 URL: https://issues.apache.org/jira/browse/MNG-5863
>             Project: Maven
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 3.3.3
>            Reporter: Petr Kozelka
>            Assignee: Christian Schulte
>             Fix For: 3.4.0
>
>   Original Estimate: 0.25h
>  Remaining Estimate: 0.25h
>
> in maven-model-builder, the file pom-4.0.0.xml defines  "release-profile" which binds some executions to the lifecycle.
> One of them is source:jar - which forks the build. That can be a problem in some configurations, and the forking is probably not necessary.
> One situation where the forked build hurts is this:
> - I have checkstyle:check attached to phase "validate"
> - some of my modules generate code, obviously not compliant to the checkstyle
> The problem is that, inside forked build, the checkstyle:check is called again, but now it checks also the generated code (because target/ is no longer empty). And of course fails.
> Even worse: during normal development iterations, everything is fine. But when I have to issue a release (usually under some pressure), I hit this problem.
> Fortunately, there _is_ a workaround: override the execution "attach-sources" and assign it to a non-existing phase, and define execution with different id for that.
> But it is too ugly and I believe that the simple fix would solve it - for the meantime before the whole profile is removed.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)