Class ShadeMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.apache.maven.plugins.shade.mojo.ShadeMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
,org.codehaus.plexus.personality.plexus.lifecycle.phase.Contextualizable
@Mojo(name="shade", defaultPhase=PACKAGE, threadSafe=true, requiresDependencyResolution=RUNTIME) public class ShadeMojo extends org.apache.maven.plugin.AbstractMojo implements org.codehaus.plexus.personality.plexus.lifecycle.phase.Contextualizable
Mojo that performs shading delegating to the Shader component.- Author:
- Jason van Zyl, Mauro Talevi, David Blevins, Hiram Chirino
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.maven.shared.transfer.artifact.resolve.ArtifactResolver
artifactResolver
Artifact resolver, needed to download source jars for inclusion in classpath.protected org.apache.maven.artifact.repository.ArtifactRepository
localRepository
Local maven repository.protected List<org.apache.maven.artifact.repository.ArtifactRepository>
remoteArtifactRepositories
Remote repositories which will be searched for source attachments.
-
Constructor Summary
Constructors Constructor Description ShadeMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
contextualize(org.codehaus.plexus.context.Context context)
void
execute()
boolean
updateExcludesInDeps(org.apache.maven.project.MavenProject project, List<org.apache.maven.model.Dependency> dependencies, List<org.apache.maven.model.Dependency> transitiveDeps)
-
-
-
Field Detail
-
remoteArtifactRepositories
@Parameter(readonly=true, required=true, defaultValue="${project.remoteArtifactRepositories}") protected List<org.apache.maven.artifact.repository.ArtifactRepository> remoteArtifactRepositories
Remote repositories which will be searched for source attachments.
-
localRepository
@Parameter(readonly=true, required=true, defaultValue="${localRepository}") protected org.apache.maven.artifact.repository.ArtifactRepository localRepository
Local maven repository.
-
artifactResolver
@Component protected org.apache.maven.shared.transfer.artifact.resolve.ArtifactResolver artifactResolver
Artifact resolver, needed to download source jars for inclusion in classpath.
-
-
Method Detail
-
contextualize
public void contextualize(org.codehaus.plexus.context.Context context) throws org.codehaus.plexus.context.ContextException
- Specified by:
contextualize
in interfaceorg.codehaus.plexus.personality.plexus.lifecycle.phase.Contextualizable
- Throws:
org.codehaus.plexus.context.ContextException
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException
- Specified by:
execute
in interfaceorg.apache.maven.plugin.Mojo
- Throws:
org.apache.maven.plugin.MojoExecutionException
- in case of an error.
-
updateExcludesInDeps
public boolean updateExcludesInDeps(org.apache.maven.project.MavenProject project, List<org.apache.maven.model.Dependency> dependencies, List<org.apache.maven.model.Dependency> transitiveDeps) throws org.apache.maven.shared.dependency.graph.DependencyGraphBuilderException
- Throws:
org.apache.maven.shared.dependency.graph.DependencyGraphBuilderException
-
-