You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Sergey Ponomarev (JIRA)" <ji...@apache.org> on 2016/04/28 22:01:12 UTC

[jira] [Updated] (MCLEAN-72) post-clean phase is not executed

     [ https://issues.apache.org/jira/browse/MCLEAN-72?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sergey Ponomarev updated MCLEAN-72:
-----------------------------------
    Description: 
clean plugin defines three phases: pre-clean, clean, and post-clean.
I bound a goal of another plugin to post-clean but it doesn't work.
For example this [configuration](http://www.avajava.com/tutorials/lessons/what-are-the-phases-of-the-maven-clean-lifecycle.html) echoes pre-clean, clean but not post-clean:
{code}
[echo] in pre-clean phase
[echo] in clean phase
{code}

However if run `mvn post-clean` everything works as expected:
{code}
[INFO] ------------------------------------------------------------------------
[INFO] Building mavenclean 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-antrun-plugin:1.1:run (id.pre-clean) @ mavenclean ---
[INFO] Executing tasks
     [echo] in pre-clean phase
[INFO] Executed tasks
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ mavenclean ---
[INFO] 
[INFO] --- maven-antrun-plugin:1.1:run (id.clean) @ mavenclean ---
[INFO] Executing tasks
     [echo] in clean phase
[INFO] Executed tasks
[INFO] 
[INFO] --- maven-antrun-plugin:1.1:run (id.post-clean) @ mavenclean ---
[INFO] Executing tasks
     [echo] in post-clean phase
[INFO] Executed tasks
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
{code}




  was:
clean plugin defines three phases: pre-clean, clean, and post-clean.
I bound a goal of another plugin to post-clean but it doesn't work.
For example this <a href="http://www.avajava.com/tutorials/lessons/what-are-the-phases-of-the-maven-clean-lifecycle.html">configuration</a> echoes pre-clean, clean but not post-clean:
{code}
[echo] in pre-clean phase
[echo] in clean phase
{code}

However if run `mvn post-clean` everything works as expected:
{code}
[INFO] ------------------------------------------------------------------------
[INFO] Building mavenclean 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-antrun-plugin:1.1:run (id.pre-clean) @ mavenclean ---
[INFO] Executing tasks
     [echo] in pre-clean phase
[INFO] Executed tasks
[INFO] 
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ mavenclean ---
[INFO] 
[INFO] --- maven-antrun-plugin:1.1:run (id.clean) @ mavenclean ---
[INFO] Executing tasks
     [echo] in clean phase
[INFO] Executed tasks
[INFO] 
[INFO] --- maven-antrun-plugin:1.1:run (id.post-clean) @ mavenclean ---
[INFO] Executing tasks
     [echo] in post-clean phase
[INFO] Executed tasks
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
{code}





> post-clean phase is not executed
> --------------------------------
>
>                 Key: MCLEAN-72
>                 URL: https://issues.apache.org/jira/browse/MCLEAN-72
>             Project: Maven Clean Plugin
>          Issue Type: Bug
>    Affects Versions: 2.5, 3.0.0
>         Environment: Windows
>            Reporter: Sergey Ponomarev
>
> clean plugin defines three phases: pre-clean, clean, and post-clean.
> I bound a goal of another plugin to post-clean but it doesn't work.
> For example this [configuration](http://www.avajava.com/tutorials/lessons/what-are-the-phases-of-the-maven-clean-lifecycle.html) echoes pre-clean, clean but not post-clean:
> {code}
> [echo] in pre-clean phase
> [echo] in clean phase
> {code}
> However if run `mvn post-clean` everything works as expected:
> {code}
> [INFO] ------------------------------------------------------------------------
> [INFO] Building mavenclean 1.0-SNAPSHOT
> [INFO] ------------------------------------------------------------------------
> [INFO] 
> [INFO] --- maven-antrun-plugin:1.1:run (id.pre-clean) @ mavenclean ---
> [INFO] Executing tasks
>      [echo] in pre-clean phase
> [INFO] Executed tasks
> [INFO] 
> [INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ mavenclean ---
> [INFO] 
> [INFO] --- maven-antrun-plugin:1.1:run (id.clean) @ mavenclean ---
> [INFO] Executing tasks
>      [echo] in clean phase
> [INFO] Executed tasks
> [INFO] 
> [INFO] --- maven-antrun-plugin:1.1:run (id.post-clean) @ mavenclean ---
> [INFO] Executing tasks
>      [echo] in post-clean phase
> [INFO] Executed tasks
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> {code}



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