Maven plugin execution order
<p>I have problem with ordering Maven plugin executions.
I would like to execute the plugins in declaration order:</p>

<pre><code>&lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
    &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
    &lt;groupId&gt;test&lt;/groupId&gt;
    &lt;artifactId&gt;test&lt;/artifactId&gt;
    &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
    &lt;build&gt;
        &lt;plugins&gt;
            &lt;plugin&gt;
                &lt;artifactId&gt;maven-antrun-plugin&lt;/artifactId&gt;
                &lt;executions&gt;
                    &lt;execution&gt;
                        &lt;id&gt;task-1&lt;/id&gt;
                        &lt;goals&gt;
                            &lt;goal&gt;run&lt;/goal&gt;
                        &lt;/goals&gt;
                        &lt;phase&gt;initialize&lt;/phase&gt;
                        &lt;configuration&gt;
                            &lt;target&gt;
                            &lt;/target&gt;
                        &lt;/configuration&gt;
                    &lt;/execution&gt;
                &lt;/executions&gt;
            &lt;/plugin&gt;
            &lt;plugin&gt;
                &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
                &lt;artifactId&gt;exec-maven-plugin&lt;/artifactId&gt;
                &lt;executions&gt;
                    &lt;execution&gt;
                        &lt;id&gt;task-2&lt;/id&gt;
                        &lt;goals&gt;
                            &lt;goal&gt;exec&lt;/goal&gt;
                        &lt;/goals&gt;
                        &lt;phase&gt;initialize&lt;/phase&gt;
                    &lt;/execution&gt;
                &lt;/executions&gt;
                &lt;configuration&gt;
                    &lt;executable&gt;cmd&lt;/executable&gt;
                    &lt;arguments&gt;
                        &lt;argument&gt;/c&lt;/argument&gt;
                        &lt;argument&gt;rem&lt;/argument&gt;
                    &lt;/arguments&gt;
                &lt;/configuration&gt;
            &lt;/plugin&gt;
            &lt;plugin&gt;
                &lt;artifactId&gt;maven-antrun-plugin&lt;/artifactId&gt;
                &lt;executions&gt;
                    &lt;execution&gt;
                        &lt;id&gt;task-3&lt;/id&gt;
                        &lt;goals&gt;
                            &lt;goal&gt;run&lt;/goal&gt;
                        &lt;/goals&gt;
                        &lt;phase&gt;initialize&lt;/phase&gt;
                        &lt;configuration&gt;
                            &lt;target&gt;
                            &lt;/target&gt;
                        &lt;/configuration&gt;
                    &lt;/execution&gt;
                &lt;/executions&gt;
            &lt;/plugin&gt;
        &lt;/plugins&gt;
    &lt;/build&gt;
&lt;/project&gt;
</code></pre>

<p>I expected the execution order: task-1, task-2, task-3</p>

<p>But after executing <code>mvn initialize</code>, the actual order is task-1, task-3, task-2:</p>

<pre><code>[INFO] --- maven-antrun-plugin:1.3:run (task-1) @ test ---
[INFO] Executing tasks
[INFO] Executed tasks
[INFO]
[INFO] --- maven-antrun-plugin:1.3:run (task-3) @ test ---
[INFO] Executing tasks
[INFO] Executed tasks
[INFO]
[INFO] --- exec-maven-plugin:1.4.0:exec (task-2) @ test ---
</code></pre>

<p>What should I change to execute the plugins in the order I want?</p>