maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Abel Salgado Romero (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MNG-6734) Ability to add Java sources to plugins classpath from .mvn directory
Date Thu, 15 Aug 2019 18:42:00 GMT

    [ https://issues.apache.org/jira/browse/MNG-6734?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16908402#comment-16908402
] 

Abel Salgado Romero commented on MNG-6734:
------------------------------------------

The requirement could be rephrased indeed, the main idea is to be able to inject classes without
needing additional modules like in the example: https://github.com/asciidoctor/asciidoctor-maven-examples/blob/f9580a7b22d015ce3f973099091f73802e867b3f/java-extension-example/asciidoctor-with-extension-example/pom.xml#L39.

I understand you mean that a project could have something like a gradle "sourceSet" that is
not included in the artifact but can be used by a plugin during it's execution, is that so?
If so, it would fit perfectly the need.

> Ability to add Java sources to plugins classpath from .mvn directory
> --------------------------------------------------------------------
>
>                 Key: MNG-6734
>                 URL: https://issues.apache.org/jira/browse/MNG-6734
>             Project: Maven
>          Issue Type: New Feature
>          Components: core
>            Reporter: Abel Salgado Romero
>            Priority: Minor
>
> In plugins like [asciidoctor-maven-plugin|https://github.com/asciidoctor/asciidoctor-maven-plugin]
it is possible to add Java Asciidoctor extensions and other customizations to the conversion
process.
> These need to be available to the asciidoctor-maven-plugin classpath and due to how maven
manages plugin's dependencies, this means that users need to publish these extension in a
maven repo or create multi-module projects like in this example https://github.com/asciidoctor/asciidoctor-maven-examples/tree/master/java-extension-example.
> This is cumbersome and a bit of overkill when some users just want to add a single class.
> So, I wonder if would make sense to be able to add Java sources in the ".mvn" directory
that are compiled and added to the classpath so that maven plugins can use them.
> Ideally, to avoid classpath issues, I'd like to be able to tell which plugins use the
code, maybe with an XML descriptor or some directory convention.



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

Mime
View raw message