ok. seems strange (i would like to try it on my own, unfortunately i'm lacking time to do so.) i'm using the plugin as well (only once inside the pom) but it's working fine. Maybe it has problems when defined twice.
you wrote [1]: If the url property is defined in both configurations and there is no common configuration this should work. Have you defined the plugin in a parent pom as well? (that could cause a problem if the configuration is missing the url property (and the configuration is inside the execution part, so no url information would be passed to the parent wagon definition) Have you tried both configurations on its own. (e.g. uncomment the upload and try only download and vice versa ? does this work?) [1] However, if I move the <configuration> sections to within the <execution> tag, I get this message: [INFO] One or more required plugin parameters are invalid/missing for 'wagon:download' [0] Inside the definition for plugin 'wagon-maven-plugin' specify the following: <configuration> ... <url>VALUE</url> </configuration> -----Ursprüngliche Nachricht----- Von: [email protected] [mailto:[email protected]] Gesendet: Dienstag, 6. April 2010 17:07 An: Maven Users List Betreff: Re: AW: Controlling maven... harald Unfortunately, this leads to the problem I mentioned: [INFO] One or more required plugin parameters are invalid/missing for 'wagon:download' [0] Inside the definition for plugin 'wagon-maven-plugin' specify the following: <configuration> ... <url>VALUE</url> </configuration> Maven is not picking up the execution specific configuration... Andy Bell | DST Global Solutions Limited | 44 020 8390 5000x5837 "Entner Harald" <entner.har...@af b.de> To "Maven Users List" 06/04/2010 15:55 <[email protected]> cc Please respond to Subject "Maven Users AW: Controlling maven... List" <[email protected] he.org> you don't have to declare the plugin twice, you can declare it only once and add two execution nodes.(with all required properties). Afaik, you can put configuration information that is common to both execution nodes outside the execution node and put the execution specific information into the configuration child of the execution node. e.g. <plugin...> <executions> <execution> ... <configuration>...</configuration> </execution> <execution> ... <configuration>...</configuration> </execution> </execution> <configuration> .. common configuration.. </configuration> </plugin> hope it helps harald -----Ursprüngliche Nachricht----- Von: [email protected] [mailto:[email protected]] Gesendet: Dienstag, 6. April 2010 16:46 An: [email protected] Betreff: Controlling maven... Hi I am trying to use Maven to automate a complicated process: I have 3 machines: a Maven build machine, a Project WebSite server machine and a Project Install Builder Machine. We have several builds, controlled by Hudson. After a particular build, the Project Install Builder Machine will have created an Installer and a nice set of web pages to go with it. These have been zipped up to make transferring them easier. I then need Maven to: 1) Get the project Installer from the Project Install Builder Machine (a .zip file) using FTP 2) Unzip this file to a project specific folder 3) FTP the contents this folder to the WebSite machine. I am trying to use the wagon plugin to do steps 1 and 3 but I am finding that specifying the plugin twice in the same pom.xml is causing trouble. If I try this... <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>wagon-maven-plugin</artifactId> <executions> <execution> <id>ftp-deployed-properties-files</id> <!--phase>pre-integration-test</phase--> <goals> <goal>download</goal> </goals> </execution> </executions> <configuration> <toDir>${project.build.directory}\WebInstaller</toDir> <url>ftp://anonymous:hwscr...@isbuild/WebServicesBuild/target/installanywhere/investmentaccounting_Build_Output</url> </configuration> </plugin> ... <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>wagon-maven-plugin</artifactId> <executions> <execution> <id>ftp-deployed-properties-files</id> <!--phase>pre-integration-test</phase--> <goals> <goal>upload</goal> </goals> </execution> </executions> <configuration> <fromDir>${project.build.directory}\WebInstaller\V-1.0.0.${buildNumber}\</fromDir> <url>ftp://anonymous:hwscr...@localhost</url> </configuration> </plugin> and call it with this command: mvn wagon:download wagon:upload then the <configuration> section from the upload is also used for the download. However, if I move the <configuration> sections to within the <execution> tag, I get this message: [INFO] One or more required plugin parameters are invalid/missing for 'wagon:download' [0] Inside the definition for plugin 'wagon-maven-plugin' specify the following: <configuration> ... <url>VALUE</url> </configuration> -OR- on the command line, specify: '-Dwagon.url=VALUE' I can't use the latter option because the URL is dynamically generated from the SCM version number and I need two different locations! So, it seems that the wagon plugin cannot use 2 different URL's in the same pom.xml. I know I can put the commands in separate pom's, but that seems like a poor solution to me. Andy Bell | DST Global Solutions Limited | 44 020 8390 5000x5837 http://www.dstglobalsolutions.com ***************************************************************************** >From May 18th 2009: DST International Limited will be known as DST Global Solutions Limited. DST International Output Limited will be known as DST Output Limited. Please update your address book with the new email address and visit our new websites: http://www.dstglobalsolutions.com and http://www.dstoutput.co.uk ============================================================= Notice: This e-mail and any attachments are intended only for the individual or company to which it is addressed and may contain information which is privileged, confidential and prohibited from disclosure or unauthorized use under applicable law. If you are not the intended recipient of this e-mail, you are hereby notified that any use, dissemination or copying of this e-mail or the information contained in this e-mail is strictly prohibited by the sender. Whilst we run anti-virus software on all internet e-mails we are not liable for any loss or damage. The recipient is advised to run their own anti-virus software. If you have received this transmission in error, please return the material received to the sender and delete all copies from your system. Thank you. DST Global Solutions Limited is a company registered in England and Wales with company number 1772349. DST Global Solutions Group Services Limited is a company registered in England and Wales with company number 5211646. DST Global Solutions Billing Limited is a company registered in England and Wales with company number 4370287. DST Output Limited is a company registered in England and Wales with company number 4220397. Pensions and Actuarial Services Limited is a company registered in England and Wales with company number 2957435. The registered office for all the above mentioned companies is: DST House, St Mark's Hill, Surbiton, Surrey, KT6 4QD, England. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] http://www.dstglobalsolutions.com ***************************************************************************** >From May 18th 2009: DST International Limited will be known as DST Global Solutions Limited. DST International Output Limited will be known as DST Output Limited. Please update your address book with the new email address and visit our new websites: http://www.dstglobalsolutions.com and http://www.dstoutput.co.uk ============================================================= Notice: This e-mail and any attachments are intended only for the individual or company to which it is addressed and may contain information which is privileged, confidential and prohibited from disclosure or unauthorized use under applicable law. If you are not the intended recipient of this e-mail, you are hereby notified that any use, dissemination or copying of this e-mail or the information contained in this e-mail is strictly prohibited by the sender. Whilst we run anti-virus software on all internet e-mails we are not liable for any loss or damage. The recipient is advised to run their own anti-virus software. If you have received this transmission in error, please return the material received to the sender and delete all copies from your system. Thank you. DST Global Solutions Limited is a company registered in England and Wales with company number 1772349. DST Global Solutions Group Services Limited is a company registered in England and Wales with company number 5211646. DST Global Solutions Billing Limited is a company registered in England and Wales with company number 4370287. DST Output Limited is a company registered in England and Wales with company number 4220397. Pensions and Actuarial Services Limited is a company registered in England and Wales with company number 2957435. The registered office for all the above mentioned companies is: DST House, St Mark's Hill, Surbiton, Surrey, KT6 4QD, England. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
