Generate standard maven plugin documentation

74 Views Asked by At

Maven plugins follow a standard pattern for documentation, like e.g.

https://maven.apache.org/maven-release/maven-release-plugin/index.html

with a "goals", "usage" etc. section and each goal with a dedicated page.

How can I generate such documentation for my own Maven plugin?

1

There are 1 best solutions below

0
user944849 On BEST ANSWER

Looking at one of my own projects, I think it's just this:

<reporting>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-plugin-plugin</artifactId>
            <version>${maven.plugin.plugin.version}</version>
            <reportSets>
                <reportSet>
                    <reports>
                        <report>report</report>  <!-- generates standard Maven plugin docs -->
                    </reports>
                </reportSet>
            </reportSets>
        </plugin>
    </plugins>

</reporting>

Configuration options are in the plugin docs.