I think that's correct, at least this is the behaviour that I would
expect. You wouldn't want your Maven installation be changed just
because one project uses a specific version of a dependency, would you?
-Lukas
Dennis Lundberg wrote:
Hello
A project I'm working on requires a specific version of a plugin. Is
this the correct way to specify this in project.xml? Is there anything
else that needs to be added?
<dependencies>
<dependency>
<groupId>maven</groupId>
<artifactId>maven-xdoc-plugin</artifactId>
<version>1.9.2</version>
<type>plugin</type>
</dependency>
</dependencies>
When I put this into the project and run
maven --info
it still states
maven-xdoc-plugin-1.8
Is this to be expected? I forced an error in one of our xdocs which
resulted in a BUILD FAILED message. That message states that the error
occured in
File...... C:\Documents and
Settings\dlg01\.maven\cache\maven-xdoc-plugin-1.9.2\plugin.jelly
This seems to indicate that Maven is using version 1.9.2 after all.
Running
maven -X site
show that Maven first does
Loading plugin 'maven-xdoc-plugin-1.8'
and then a little later does
Loading plugin 'maven-xdoc-plugin-1.9.2'
...
Temporarily uninstalling:
source = C:\Documents and
Settings\dlg01\.maven\cache\maven-xdoc-plugin-1.8\plugin.jelly
project = null
script = null
Installing plugin:
source = C:\Documents and
Settings\dlg01\.maven\cache\maven-xdoc-plugin-1.9.2\plugin.jelly
project = Maven XDoc Plug-in
script = null
So, to summarize, when a project has a dependency on a specific version
of a plugin, that version of the plugin is temporarily used *only* when
running Maven for that particular project. It has no effect on the
plugins installed in MAVEN_HOME/plugins or when running Maven on other
projects.
Is the above statement correct?
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]