Class CommonsSiteCompressionMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.commons.release.plugin.mojos.CommonsSiteCompressionMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Deprecated
@Mojo(name="compress-site",
defaultPhase=POST_SITE,
threadSafe=true,
aggregator=true)
public class CommonsSiteCompressionMojo
extends org.apache.maven.plugin.AbstractMojo
Deprecated.
Takes the built
./target/site directory and compresses it to
./target/commons-release-plugin/site.zip.- Since:
- 1.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate StringDeprecated.The url of the subversion repository to which we wish the artifacts to be staged.Deprecated.The list of files to compress into the site.zip file.private BooleanDeprecated.A parameter to generally avoid running unless it is specifically turned on by the consuming module.private FileDeprecated.private FileDeprecated.The working directory for the plugin which, assuming the maven uses the default${project.build.directory}, this becomestarget/commons-release-plugin.Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidaddToZip(File directoryToZip, File file, ZipOutputStream zos) Deprecated.Given thedirectoryToZipwe add thefileto the ZIP archive represented byzos.voidexecute()Deprecated.private voidgetAllSiteFiles(File siteDirectory, List<File> filesToCompress) Deprecated.By default this method iterates across thetarget/sitedirectory and adds all the files to thefilesToCompressList.private voidwriteZipFile(File outputDirectory, File directoryToZip, List<File> fileList) Deprecated.A helper method for writing all the files in ourfileListto asite.zipfile in theworkingDirectory.Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
workingDirectory
@Parameter(defaultValue="${project.build.directory}/commons-release-plugin", property="commons.outputDirectory") private File workingDirectoryDeprecated.The working directory for the plugin which, assuming the maven uses the default${project.build.directory}, this becomestarget/commons-release-plugin. -
siteDirectory
@Parameter(defaultValue="${project.build.directory}/site", property="commons.siteOutputDirectory") private File siteDirectoryDeprecated. -
distSvnStagingUrl
Deprecated.The url of the subversion repository to which we wish the artifacts to be staged. Typically this would need to be of the form:scm:svn:https://dist.apache.org/repos/dist/dev/commons/foo. Note. that the prefix to the substringhttpsis a requirement. -
isDistModule
@Parameter(defaultValue="false", property="commons.release.isDistModule") private Boolean isDistModuleDeprecated.A parameter to generally avoid running unless it is specifically turned on by the consuming module. -
filesToCompress
Deprecated.The list of files to compress into the site.zip file.
-
-
Constructor Details
-
CommonsSiteCompressionMojo
public CommonsSiteCompressionMojo()Deprecated.
-
-
Method Details
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureExceptionDeprecated.- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-
getAllSiteFiles
Deprecated.By default this method iterates across thetarget/sitedirectory and adds all the files to thefilesToCompressList. -
writeZipFile
private void writeZipFile(File outputDirectory, File directoryToZip, List<File> fileList) throws IOException Deprecated.A helper method for writing all the files in ourfileListto asite.zipfile in theworkingDirectory.- Parameters:
outputDirectory- is aFilerepresenting the place to put the site.zip file.directoryToZip- is aFilerepresenting the directory of the site (normallytarget/site).fileList- the list of files to be zipped up, generally generated bygetAllSiteFiles(File, List).- Throws:
IOException- when the copying of the files goes incorrectly.
-
addToZip
Deprecated.Given thedirectoryToZipwe add thefileto the ZIP archive represented byzos.- Parameters:
directoryToZip- aFilerepresenting the directory from which the file exists that we are compressing. Generally this istarget/site.file- aFileto add to theZipOutputStreamzos.zos- theZipOutputStreamto which to add ourfile.- Throws:
IOException- if adding thefiledoesn't work out properly.
-
CommonsDistributionStagingMojo.