You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by eyal edri <ey...@gmail.com> on 2010/03/24 10:20:57 UTC

maven plugin to run a command line after 'deploy' phase

is there a maven plugin i can use in order to run a bash script/code after
the deploy phase is run?

thanks!

-- 
Eyal Edri

Re: maven plugin to run a command line after 'deploy' phase

Posted by Anders Hammar <an...@hammar.net>.
I believe bound plugins are executed in the order they are declared. I would
assume that the effective-pom shows this. However, I think I rememeber an
earlier discussion about that this could depend on the version of Maven
you're using.
In any case, having two plugins requiring a specific execution order bound
to the same phase is not best-practise.
Also, a bash script is os dependent and wouldn't work on Windows for
instance. I would try to move to something platform independent.

/Anders
On Wed, Mar 24, 2010 at 11:22, eyal edri <ey...@gmail.com> wrote:

> i know, but somehow (don't know exactly why), it runs after another plugin
> that runs in the deploy phase (which was my intention) , maybe because it's
> written after it the pom?
>
> /Eyal
>
> On Wed, Mar 24, 2010 at 12:10 PM, Anders Hammar <an...@hammar.net> wrote:
>
> > You know this won't be run *after* the deploy phase (as asked), but in
> that
> > phase? The deploy phase is the last phase btw.
> >
> > /Anders
> >
> > On Wed, Mar 24, 2010 at 10:56, eyal edri <ey...@gmail.com> wrote:
> >
> > > found it! :)
> > >
> > > <plugin>
> > >        <artifactId>maven-antrun-plugin</artifactId>
> > >        <executions>
> > >          <execution>
> > >            <phase>deploy</phase>
> > >            <configuration>
> > >              <tasks>
> > >                <exec
> > >                  dir="${basedir}"
> > >
>  executable="${basedir}/src/main/scripts/run-yum-make.sh"
> > >                  failonerror="true">
> > >                </exec>
> > >              </tasks>
> > >            </configuration>
> > >            <goals>
> > >              <goal>run</goal>
> > >            </goals>
> > >          </execution>
> > >        </executions>
> > >      </plugin>
> > >
> > > On Wed, Mar 24, 2010 at 11:20 AM, eyal edri <ey...@gmail.com>
> wrote:
> > >
> > > > is there a maven plugin i can use in order to run a bash script/code
> > > after
> > > > the deploy phase is run?
> > > >
> > > > thanks!
> > > >
> > > > --
> > > > Eyal Edri
> > > >
> > >
> > >
> > >
> > > --
> > > Eyal Edri
> > >
> >
>
>
>
> --
> Eyal Edri
>

Re: maven plugin to run a command line after 'deploy' phase

Posted by eyal edri <ey...@gmail.com>.
i know, but somehow (don't know exactly why), it runs after another plugin
that runs in the deploy phase (which was my intention) , maybe because it's
written after it the pom?

/Eyal

On Wed, Mar 24, 2010 at 12:10 PM, Anders Hammar <an...@hammar.net> wrote:

> You know this won't be run *after* the deploy phase (as asked), but in that
> phase? The deploy phase is the last phase btw.
>
> /Anders
>
> On Wed, Mar 24, 2010 at 10:56, eyal edri <ey...@gmail.com> wrote:
>
> > found it! :)
> >
> > <plugin>
> >        <artifactId>maven-antrun-plugin</artifactId>
> >        <executions>
> >          <execution>
> >            <phase>deploy</phase>
> >            <configuration>
> >              <tasks>
> >                <exec
> >                  dir="${basedir}"
> >                  executable="${basedir}/src/main/scripts/run-yum-make.sh"
> >                  failonerror="true">
> >                </exec>
> >              </tasks>
> >            </configuration>
> >            <goals>
> >              <goal>run</goal>
> >            </goals>
> >          </execution>
> >        </executions>
> >      </plugin>
> >
> > On Wed, Mar 24, 2010 at 11:20 AM, eyal edri <ey...@gmail.com> wrote:
> >
> > > is there a maven plugin i can use in order to run a bash script/code
> > after
> > > the deploy phase is run?
> > >
> > > thanks!
> > >
> > > --
> > > Eyal Edri
> > >
> >
> >
> >
> > --
> > Eyal Edri
> >
>



-- 
Eyal Edri

Re: maven plugin to run a command line after 'deploy' phase

Posted by Anders Hammar <an...@hammar.net>.
You know this won't be run *after* the deploy phase (as asked), but in that
phase? The deploy phase is the last phase btw.

/Anders

On Wed, Mar 24, 2010 at 10:56, eyal edri <ey...@gmail.com> wrote:

> found it! :)
>
> <plugin>
>        <artifactId>maven-antrun-plugin</artifactId>
>        <executions>
>          <execution>
>            <phase>deploy</phase>
>            <configuration>
>              <tasks>
>                <exec
>                  dir="${basedir}"
>                  executable="${basedir}/src/main/scripts/run-yum-make.sh"
>                  failonerror="true">
>                </exec>
>              </tasks>
>            </configuration>
>            <goals>
>              <goal>run</goal>
>            </goals>
>          </execution>
>        </executions>
>      </plugin>
>
> On Wed, Mar 24, 2010 at 11:20 AM, eyal edri <ey...@gmail.com> wrote:
>
> > is there a maven plugin i can use in order to run a bash script/code
> after
> > the deploy phase is run?
> >
> > thanks!
> >
> > --
> > Eyal Edri
> >
>
>
>
> --
> Eyal Edri
>

Re: maven plugin to run a command line after 'deploy' phase

Posted by eyal edri <ey...@gmail.com>.
found it! :)

<plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <executions>
          <execution>
            <phase>deploy</phase>
            <configuration>
              <tasks>
                <exec
                  dir="${basedir}"
                  executable="${basedir}/src/main/scripts/run-yum-make.sh"
                  failonerror="true">
                </exec>
              </tasks>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

On Wed, Mar 24, 2010 at 11:20 AM, eyal edri <ey...@gmail.com> wrote:

> is there a maven plugin i can use in order to run a bash script/code after
> the deploy phase is run?
>
> thanks!
>
> --
> Eyal Edri
>



-- 
Eyal Edri