Class ManpagePost

java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.forgerock.doc.maven.AbstractDocbkxMojo
org.forgerock.doc.maven.post.ManpagePost
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

public class ManpagePost extends AbstractDocbkxMojo
Fix man page file locations.
  • Constructor Details

    • ManpagePost

      Constructor setting the Mojo that holds the configuration.
      Parameters:
      mojo - The Mojo that holds the configuration.
  • Method Details

    • execute

      public void execute() throws org.apache.maven.plugin.MojoExecutionException
      Fix man page file locations.
      Man page generation replaces spaces in path name with underscores. As a result, if man pages are built in a project directory like /path/to/My Doc Project, then the generated man pages end up by default in /path/to/My_Doc_Project/target/docbkx/manpages.
      This method copies the result to the expected location.
      This method then attempts to remove the extra generated directory, though failure to remove the extra directory only logs an informational message and does no throw an exception.
      Throws:
      org.apache.maven.plugin.MojoExecutionException - Failed to copy files.