Package org.eclipse.tycho.source
Class SourceFeatureMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.eclipse.tycho.source.SourceFeatureMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="feature-source", defaultPhase=PACKAGE, threadSafe=true) public class SourceFeatureMojo extends org.apache.maven.plugin.AbstractMojoGenerates a source feature for projects of packaging typeeclipse-feature. By default, the generated source feature- Declares feature id
<originalFeatureId>.source - Declares feature label
"<originalFeatureLabel> Developer Resources" - If present, reuses feature provider, description, copyright and license as well as respective URLs from <originalFeature>
- Includes all plugins included by <originalFeature>, but each with
.sourceappended to each plugin id - Includes all features included by <originalFeature>, but each with
.sourceappended to each feature id - Includes the original feature. This ensures that binaries and corresponding sources match.
sourceTemplateFeature/. Files added here will be added to the root of the source feature jar. Especially, if filesourceTemplateFeature/feature.propertiesis found, values in this file override values of respective keys in<originalFeature>/feature.properties.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSourceFeatureMojo.MissingSourcesAction
-
Field Summary
Fields Modifier and Type Field Description static StringFEATURE_TEMPLATE_DIRstatic StringSOURCES_FEATURE_CLASSIFIERprotected booleanuseDefaultExcludes
-
Constructor Summary
Constructors Constructor Description SourceFeatureMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddPlugin(org.eclipse.tycho.model.Feature sourceFeature, org.eclipse.tycho.p2.resolver.facade.P2ResolutionResult result, org.eclipse.tycho.model.PluginRef pluginRef)voidexecute()protected org.codehaus.plexus.archiver.FileSetgetFileSet(File basedir, List<String> includes, List<String> excludes)protected FilegetOutputJarFile()protected booleanisP2GenerationEnabled()voidsetExcludes(org.codehaus.plexus.configuration.PlexusConfiguration excludes)voidsetPlugins(org.codehaus.plexus.configuration.PlexusConfiguration bundles)protected StringtoStrictVersionRange(String version)
-
-
-
Field Detail
-
FEATURE_TEMPLATE_DIR
public static final String FEATURE_TEMPLATE_DIR
- See Also:
- Constant Field Values
-
SOURCES_FEATURE_CLASSIFIER
public static final String SOURCES_FEATURE_CLASSIFIER
- See Also:
- Constant Field Values
-
useDefaultExcludes
@Parameter(defaultValue="true") protected boolean useDefaultExcludes
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-
isP2GenerationEnabled
protected boolean isP2GenerationEnabled()
-
addPlugin
protected void addPlugin(org.eclipse.tycho.model.Feature sourceFeature, org.eclipse.tycho.p2.resolver.facade.P2ResolutionResult result, org.eclipse.tycho.model.PluginRef pluginRef)
-
getOutputJarFile
protected File getOutputJarFile()
-
setExcludes
public void setExcludes(org.codehaus.plexus.configuration.PlexusConfiguration excludes)
-
setPlugins
public void setPlugins(org.codehaus.plexus.configuration.PlexusConfiguration bundles)
-
-