Package org.apache.maven.plugins.clean
Class CleanMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.apache.maven.plugins.clean.CleanMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
@Mojo(name="clean", threadSafe=true) public class CleanMojo extends org.apache.maven.plugin.AbstractMojo
Goal which cleans the build.This attempts to clean a project's working directory of the files that were generated at build-time. By default, it discovers and deletes the directories configured in
project.build.directory
,project.build.outputDirectory
,project.build.testOutputDirectory
, andproject.reporting.outputDirectory
.Files outside the default may also be included in the deletion by configuring the
filesets
tag.- Since:
- 2.0
- Author:
- Emmanuel Venisse
- See Also:
Fileset
-
-
Field Summary
Fields Modifier and Type Field Description static String
FAST_MODE_AT_END
static String
FAST_MODE_BACKGROUND
static String
FAST_MODE_DEFER
-
Constructor Summary
Constructors Constructor Description CleanMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
execute()
Deletes file-sets in the following project build directory order: (source) directory, output directory, test directory, report directory, and then the additional file-sets.
-
-
-
Field Detail
-
FAST_MODE_BACKGROUND
public static final String FAST_MODE_BACKGROUND
- See Also:
- Constant Field Values
-
FAST_MODE_AT_END
public static final String FAST_MODE_AT_END
- See Also:
- Constant Field Values
-
FAST_MODE_DEFER
public static final String FAST_MODE_DEFER
- See Also:
- Constant Field Values
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException
Deletes file-sets in the following project build directory order: (source) directory, output directory, test directory, report directory, and then the additional file-sets.- Throws:
org.apache.maven.plugin.MojoExecutionException
- When a directory failed to get deleted.- See Also:
Mojo.execute()
-
-