You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Herve Boutemy (JIRA)" <ji...@codehaus.org> on 2014/05/03 17:55:10 UTC
[jira] (MPLUGIN-160) PluginDescriptorGenerator doesn't generate
component requirements for MojoDescriptor.getRequirements()
[ https://jira.codehaus.org/browse/MPLUGIN-160?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Herve Boutemy updated MPLUGIN-160:
----------------------------------
Description:
The part that generates the <requirements> section for a mojo in PluginDescriptorGenerator, only includes requirements for components, if they are specified via a parameter with expression=$\{component.*}, not if it is actually specified as a required component using the <components> element.
I have created a patch, which includes the ComponentRequirements as requirements when generating the <requirements> element.
Until released, the following workaround can be used in the module.mojos.xml, to get the required component in the plugin.xml:
{code:xml} <parameter>
<name>workaroundForPathTransformer</name>
<required>true</required>
<expression>${component.org.apache.maven.project.path.PathTranslator}</expression>
<type>org.apache.maven.project.path.PathTranslator</type>
<description>This is a workaround to get the PathTransformer as a Requirement in the plugin.xml.</description>
</parameter>{code}
was:
The part that generates the <requirements> section for a mojo in PluginDescriptorGenerator, only includes requirements for components, if they are specified via a parameter with expression=${component.*}, not if it is actually specified as a required component using the <components> element.
I have created a patch, which includes the ComponentRequirements as requirements when generating the <requirements> element.
Until released, the following workaround can be used in the module.mojos.xml, to get the required component in the plugin.xml:
<parameter>
<name>workaroundForPathTransformer</name>
<required>true</required>
<expression>${component.org.apache.maven.project.path.PathTranslator}</expression>
<type>org.apache.maven.project.path.PathTranslator</type>
<description>This is a workaround to get the PathTransformer as a Requirement in the plugin.xml.</description>
</parameter>
> PluginDescriptorGenerator doesn't generate component requirements for MojoDescriptor.getRequirements()
> ------------------------------------------------------------------------------------------------------
>
> Key: MPLUGIN-160
> URL: https://jira.codehaus.org/browse/MPLUGIN-160
> Project: Maven Plugin Tools
> Issue Type: Bug
> Components: API
> Affects Versions: 2.5
> Reporter: Stefan Grinsted
> Priority: Minor
> Attachments: patch.txt
>
>
> The part that generates the <requirements> section for a mojo in PluginDescriptorGenerator, only includes requirements for components, if they are specified via a parameter with expression=$\{component.*}, not if it is actually specified as a required component using the <components> element.
> I have created a patch, which includes the ComponentRequirements as requirements when generating the <requirements> element.
> Until released, the following workaround can be used in the module.mojos.xml, to get the required component in the plugin.xml:
> {code:xml} <parameter>
> <name>workaroundForPathTransformer</name>
> <required>true</required>
> <expression>${component.org.apache.maven.project.path.PathTranslator}</expression>
> <type>org.apache.maven.project.path.PathTranslator</type>
> <description>This is a workaround to get the PathTransformer as a Requirement in the plugin.xml.</description>
> </parameter>{code}
--
This message was sent by Atlassian JIRA
(v6.1.6#6162)