ant - maven antrun plugin -


i have following in pom:

<plugin>     <groupid>org.apache.maven.plugins</groupid>     <artifactid>maven-ant-plugin</artifactid>     <version>2.3</version>     <configuration>        <target>           <echo             message="hello ant, maven!" />           <echo>maybe work?</echo>        </target>     </configuration> </plugin> 

yet, when run 'mvn antrun:run' this:

[info] scanning projects... [info] searching repository plugin prefix: 'antrun'. [info] ------------------------------------------------------------------------ [info] building myproject [info]    task-segment: [antrun:run] [info] ------------------------------------------------------------------------ [info] [antrun:run {execution: default-cli}] [info] executing tasks [info] executed tasks [info] ------------------------------------------------------------------------ [info] build successful [info] ------------------------------------------------------------------------ [info] total time: 1 second [info] finished at: fri sep 24 13:33:14 pdt 2010 [info] final memory: 16m/28m [info] ------------------------------------------------------------------------ 

how come echo's don't show up?

tia

because supposed use maven antrun plugin if want execute ant tasks, not maven ant plugin (which used generate build files ant 1.6.2 or above pom). modify plugin configuration below:

  <plugin>     <groupid>org.apache.maven.plugins</groupid>     <artifactid>maven-antrun-plugin</artifactid>     <version>1.5</version>     <configuration>       <target>         <echo message="hello ant, maven!"/>         <echo>maybe work?</echo>       </target>     </configuration>   </plugin> 

and invoking antrun:run work:

 $ mvn antrun:run  [info] scanning projects... [info]                                                                          [info] ------------------------------------------------------------------------ [info] building q3790798 1.0-snapshot [info] ------------------------------------------------------------------------ [info]  [info] --- maven-antrun-plugin:1.5:run (default-cli) @ q3790798 --- [info] executing tasks  main:      [echo] hello ant, maven!      [echo] maybe work? [info] executed tasks [info] ------------------------------------------------------------------------ [info] build success [info] ------------------------------------------------------------------------ ... 

Comments

Popular posts from this blog

unicode - Are email addresses allowed to contain non-alphanumeric characters? -

C#: Application without a window or taskbar item (background app) that can still use Console.WriteLine() -

c++ - Convert big endian to little endian when reading from a binary file -