Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
Description
The install and deploy tasks don't seem to be able to handle attached artefacts. There appear to be two sides to the problem: first, there seems to be no way to attach anything, and second, even if it were attached, the install and deploy tasks don't do anything with attachments.
The latter could be solved by adding to the install (and similar to the deploy) task something along the lines of (similar to the InstallMojo in the install plugin):
List attachedArtifacts = pom.getMavenProject().getAttachedArtifacts();
for (Iterator i = attachedArtifacts.iterator(); i.hasNext(); ) {
Artifact attached = (Artifact) i.next();
installer.install(attached.getFile(), attached, localRepo);
}
For the former (how to attach anything), a new task could be added (say, 'attach', taking a type, classifier and file).
This functionality is needed to handle source archives and EJB client jars.
Issue Links
- relates to
-
MANTTASKS-42
Allow install and deploy tasks to include attached artifacts
-
Alternatively, a nested fileset could be added to install and deploy tasks... Then the attachments would not be handled the 'maven way', but more the 'ant way'. Since maven plugins cannot be executed in this mode anyway, perhaps there is no need to support the proper attachments.