Hi devs while playing with the m2 eclipse plugin trying to add support for source attachments I was stuck with some inconsistencies in artifact naming.
Actually the m2 source plugin (JarSourceMojo) generates the name for the jar file using finalName + "-sources.jar". This means that, given a jar artifact such as junit-3.8.1.jar (full path in repo M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar) it generates a jar named junit-3.8.1-sources.jar. This not only makes "sources" look like a part of the version token, but, if I am not missing something, it makes impossible to reference such artifact using maven APIs. None of these can work: artifactFactory.createArtifact( "junit", "junit", "3.8.1", null, "-sources.jar" ); -> resolved to M2_REPO/junit/junit/3.8.1/junit-3.8.1.-sources.jar artifactFactory.createArtifact( "junit", "junit", "3.8.1-sources", null, ".jar" ); -> resolved to M2_REPO/junit/junit/3.8.1-sources/junit-3.8.1-sources.jar What about start managing source archives as proper artifacts and assign them a type? We could use "src.jar" as the standard artifact type so that artifactFactory.createArtifact( "junit", "junit", "3.8.1", null, "src.jar" ) can be used? If this is ok I could try to provide a patch for the source and eclipse plugins which will add a basic support for uploading/downloading source zip... fabrizio --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
