As a quick and dirty fix I add the following goal to the maven.xml of
our projects and tell people to run it if they get plugin problems

<goal name="antelope:upgradePlugins">
                <j:forEach var="dep" items="${pom.dependencies}">
                                <j:if test="${dep.type =='plugin'}">
                                        <maven:get plugin="${dep.artifactId}" 
property="plugin" 
                                                var="plugin" />
                                        
                                                <ant:echo> 
###################################################################### 
Fetching ${dep.artifactId} Plugin You may have to run your goal again 
###################################################################### 
                                </ant:echo>
                                                <j:set var="groupId" 
value="${dep.groupId}"/>
                                                <j:set var="artifactId" 
value="${dep.artifactId}"/>
                                                <j:set var="version" 
value="${dep.version}"/>
                                                <attainGoal name="plugin:download"/>
                                        </j:if>

                </j:forEach>            
        </goal>


On Fri, 29 Oct 2004 06:35:28 +1000, Brett Porter <[EMAIL PROTECTED]> wrote:
> I would suggest that the plugin dependency will work, but only if you
> uninstall the original.
> 
> The mechanism has problems when two different versions of on plugin are loaded.
> 
> 
> 
> 
> On Thu, 28 Oct 2004 09:34:35 -0700, Charles Daniels <[EMAIL PROTECTED]> wrote:
> > This is a known issue.  Adding a plugin as a dependency doesn't quite
> > work as you might expect.  In fact, in my experience, adding a plugin as
> > a dependency can cause other little problems.  I suggest you remove the
> > plugin as a dependency and manually download the plugin via the
> > plugin:download goal.  You should probably also manually delete the
> > plugin jar files from your MAVEN_HOME/plugins directory prior to running
> > plugin:download.  If you simply stick to using plugin:download whenever
> > you wish to upgrade to a newer plugin version, your older version will
> > automatically be removed.
> >
> >
> >
> > > -----Original Message-----
> > > From: Helck, Christopher [mailto:[EMAIL PROTECTED]
> > > Sent: Thursday, October 28, 2004 9:27 AM
> > > To: Maven Users List
> > > Subject: Need help with upgrading a plugin
> > >
> > > Note: This is a repost/rephrasing of an ealier question I sent out.
> > >
> > > Previous posts have led me to believe that I can upgrade a plugin by
> > > specifying the plugin in my POM. I've tried this and it
> > > partially works.
> > > The new plugin is downloaded and installed in my local repository, but
> > > Maven does not invoke the updated plugin. In this case I'm
> > > trying to use
> > > the latest version of the JXR plugin.
> > >
> > > Here's the relevent parts of my POM:
> > >
> > >   <dependencies>
> > >     <dependency>
> > >       <groupId>maven</groupId>
> > >       <artifactId>maven-jxr-plugin</artifactId>
> > >       <version>1.4.2</version>
> > >       <type>plugin</type>
> > >     </dependency>
> > >     ...
> > >   </dependencies>
> > >
> > >   <reports>
> > >     <report>maven-jxr-plugin</report>
> > >     ...
> > >   </reports>
> > >
> > >
> > > When I run "maven site" and it tries to build the java cross
> > > reference I
> > > get the error:
> > >
> > > BUILD FAILED
> > > File.... /home/chelck/.maven/cache/maven-jxr-plugin-1.4.1/plugin.jelly
> > >
> > > Version 1.4.2 of jxr is downloaded and in my cache next to
> > > 1.4.1. So why
> > > isn't 1.4.2 being used?
> > >
> > > Any ideas? Thanks,
> > >
> > > -c. helck
> > >
> > >
> > >
> > > The information contained in this e-mail is confidential.
> > > This e-mail is intended only for the stated addressee.  If
> > > you are not an addressee, you must not disclose, copy,
> > > circulate or in any other way use or rely on the information
> > > contained in this e-mail. if you have received this e-mail in
> > > error, please inform us immediately and delete it and all
> > > copies from your system.
> > >
> > > EBS Dealing Resources International Limited.  Registered
> > > address:  55-56 Lincoln's Inn Fields, London WC2A 3LJ, United
> > > Kingdom. Registered number 2669861.
> > >
> > > EBS Dealing Resources, Inc, registered in Delaware. Address:
> > > 535 Madison Avenue, 24th Floor, New York, NY 10022, USA, and
> > > One upper Pond road, Building F - Floor 3, Parsippany, NJ 07054, USA.
> > >
> > > EBS Dealing Resources Japan Limited, a Japanese Corporation.
> > > Address: Asteer Kayabacho Bldg, 6th Floor, 1-6-1, Shinkawa,
> > > Chuo-Ku,  Tokyo 104-0033, Japan.
> > >
> > >
> >
> >
> > ---------------------------------------------------------------------
> > 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]
> 
> 


-- 
Thanks

Ben

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to