PageRenderTime 22ms CodeModel.GetById 11ms app.highlight 7ms RepoModel.GetById 1ms app.codeStats 0ms

/maven-amps-plugin/src/main/java/com/atlassian/maven/plugins/amps/CopyBundledDependenciesMojo.java

https://bitbucket.org/mmeinhold/amps
Java | 29 lines | 23 code | 3 blank | 3 comment | 1 complexity | ea36a08beed9f9977e4dd25dae6d2028 MD5 | raw file
 1package com.atlassian.maven.plugins.amps;
 2
 3import org.apache.maven.plugin.MojoExecutionException;
 4import org.apache.maven.plugin.MojoFailureException;
 5import org.apache.maven.plugins.annotations.Mojo;
 6import org.apache.maven.plugins.annotations.Parameter;
 7import org.apache.maven.plugins.annotations.ResolutionScope;
 8
 9/**
10 * Copies bundled dependencies into META-INF/lib
11 */
12@Mojo(name = "copy-bundled-dependencies", requiresDependencyResolution = ResolutionScope.RUNTIME)
13public class CopyBundledDependenciesMojo extends AbstractAmpsMojo
14{
15    @Parameter(property = "extractDependencies", defaultValue = "true")
16    private Boolean extractDependencies;
17
18    public void execute() throws MojoExecutionException, MojoFailureException
19    {
20        if (!extractDependencies)
21        {
22            getMavenGoals().copyBundledDependencies();
23        }
24        else
25        {
26            getMavenGoals().extractBundledDependencies();
27        }
28    }
29}