FW: Maven antrun plugin

2009-02-12 Thread Kevin Witten
Sorry for the repost, but I'm not sure if this went through as I was not on the 
subscription list.


-Original Message-
From: Kevin Witten
Sent: Thursday, February 12, 2009 11:53 AM
To: 'Maven Users List'
Subject: Maven antrun plugin

Any help appreciated:

I'm trying to run an ant task on clean using maven 2.0.9. So I'm basically 
following examples from
The book Maven - The Definitive Guide. I created a simple pom.xml shown 
below, which uses the
antrun plugin configured to run echo tasks. This is set up to run on phase 
pre-clean,
so the echo message should be displayed before the clean. But it does not work.

When I run clean, I do not get the echo.

$ mvn clean
[INFO] Scanning for projects...
[INFO] 
[INFO] Building test
[INFO]task-segment: [clean]
[INFO] 
[INFO] [clean:clean]
[INFO] 
[INFO] BUILD SUCCESSFUL
[INFO] 
[INFO] Total time:  1 second
[INFO] Finished at: Thu Feb 12 11:50:54 PST 2009
[INFO] Final Memory: 3M/6M
[INFO] 


?xml version=1.0 encoding=UTF-8?
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;

   modelVersion4.0.0/modelVersion
   groupIdcom.nomadix/groupId
   artifactIdtest/artifactId
   nametest/name
   version1.0.0/version

   build
  pluginManagement
 plugins
plugin
   groupIdorg.apache.maven.plugins/groupId
   artifactIdmaven-antrun-plugin/artifactId
   executions
  execution
 idfile-exists/id
 phasepre-clean/phase
 goals
goalrun/goal
 /goals
 configuration
tasks
   
echo***/echo
   echoRunning Clean/echo
   
echo***/echo
/tasks
 /configuration
  /execution
   /executions
/plugin
 /plugins
  /pluginManagement
   /build
/project


Thanks in advance for the help,
Kevin

Notice● The information and attachment(s) contained in this communication are 
intended for the addressee only, and may be confidential and/or legally 
privileged.  If you have received this communication in error, please contact 
the sender immediately, and delete this communication from any computer or 
network system.  Any interception, review, printing, copying, re-transmission, 
dissemination, or other use of, or taking of any action upon this information 
by persons or entities other than the intended recipient is strictly prohibited 
by law and may subject them to criminal or civil liability.  None of the 
interTouch Group of Companies shall be liable for the improper and/or 
incomplete transmission of the information contained in this communication or 
for any delay in its receipt.


Re: FW: Maven antrun plugin

2009-02-12 Thread Wayne Fay
 Sorry for the repost, but I'm not sure if this went through as I was not on 
 the subscription list.
It did.

  pluginManagement
 plugins
plugin
   groupIdorg.apache.maven.plugins/groupId
   artifactIdmaven-antrun-plugin/artifactId

Node pluginManagement is used strictly for configuring plugins. The
plugins are not bound to the execution unless you declare them in the
buildplugins node as well.

build
plugins
plugin
groupIdorg.apache.maven.plugins/groupId
artifactIdmaven-antrun-plugin/artifactId
/plugin
/plugins
/build

Wayne

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org