tidy:tidy

Full name:

net.sourceforge.docbook-utils.maven-plugin:maven-tidy-plugin:1.0.0.beta-1:tidy

Description:

A plug-in for cleaning up HTML, XHTML and XML files, based on JTidy.

Attributes:

  • Requires a Maven 2.0 project to be executed.
  • Binds by default to the lifecycle phase: pre-site.

Required Parameters

Name Type Since Description
sourceDir File - The directory, from which the search for source files starts, see also sourceFiles.

Including DocBook content in a project site
In case the docbkx-maven-plugin is used to convert DocBook content into HTML pages, which should be included in the project site, use then as source directory:

${project.build.directory}/docbkx/html



Optional Parameters

Name Type Since Description
destinationDir File - The directory where the cleaned up files are placed.

Including DocBook content in a project site
In case the docbkx-maven-plugin is used to convert DocBook content into HTML pages, which should be included in the project site, use then as destination directory:

${project.build.directory}/generated-site/xhtml/docbook

Default value is: ${project.build.directory}/tidy.
jtidyConfiguration Properties - Specify the JTidy configuration properties.
replaceExtensionMap Map - In cases where the created file should have a different file extension, this option can be used.

Example of replacing html with xhtml:

<replaceExtensionMap>
  <html>xhtml</html>
</replaceExtensionMap>



skipTidy Boolean - Skip tidy-ing. Useful in cases when temporary no cleaning is needed. To speedup the build process.

The option can be added to the plug-ins configuration.

Or as JVM option on the command line:

-DskipTidy=true



Default value is: false.
sourceFiles String[] - List of source file patterns to scan for. The given patterns are used for scanning for files that need to be clean up. The base directory, from which the scanning starts is given through the sourceDir.

Some examples of possible patterns:

filename.xml
*.xml
help*.xml
directory/filename.xml
directory/*.xml
directory/directory/*.xml
directory/**/*.xml

Default values are:

**/*.html
**/*.xhtml
**/*.xml

Parameter Details

destinationDir:

The directory where the cleaned up files are placed.

Including DocBook content in a project site
In case the docbkx-maven-plugin is used to convert DocBook content into HTML pages, which should be included in the project site, use then as destination directory:

${project.build.directory}/generated-site/xhtml/docbook
  • Type: java.io.File
  • Required: No
  • Default: ${project.build.directory}/tidy

jtidyConfiguration:

Specify the JTidy configuration properties.
  • Type: java.util.Properties
  • Required: No

replaceExtensionMap:

In cases where the created file should have a different file extension, this option can be used.

Example of replacing html with xhtml:

<replaceExtensionMap>
  <html>xhtml</html>
</replaceExtensionMap>


  • Type: java.util.Map
  • Required: No

skipTidy:

Skip tidy-ing. Useful in cases when temporary no cleaning is needed. To speedup the build process.

The option can be added to the plug-ins configuration.

Or as JVM option on the command line:

-DskipTidy=true


  • Type: java.lang.Boolean
  • Required: No
  • Default: false

sourceDir:

The directory, from which the search for source files starts, see also sourceFiles.

Including DocBook content in a project site
In case the docbkx-maven-plugin is used to convert DocBook content into HTML pages, which should be included in the project site, use then as source directory:

${project.build.directory}/docbkx/html


  • Type: java.io.File
  • Required: Yes

sourceFiles:

List of source file patterns to scan for. The given patterns are used for scanning for files that need to be clean up. The base directory, from which the scanning starts is given through the sourceDir.

Some examples of possible patterns:

filename.xml
*.xml
help*.xml
directory/filename.xml
directory/*.xml
directory/directory/*.xml
directory/**/*.xml

Default values are:

**/*.html
**/*.xhtml
**/*.xml
  • Type: java.lang.String[]
  • Required: No