简体   繁体   中英

Generate standard maven plugin documentation

Maven plugins follow a standard pattern for documentation, like eg

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?

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 .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM