Reputation: 11
I found out that Maven can generate javadoc for me, and i put this plugin where i got from the internet
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.2</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
<tags>
...
</tags>
</plugin>
and it seems it doesn't work with the plugin or i just missing out on something also when i hover on the version, it says
Description : The version (or valid range of versions) of the plugin to be used.
Version : 4.0.0+
I'm expectin to have javadoc for my classes, methods and datafields using Maven.
Upvotes: 0
Views: 111
Reputation: 6111
By default, specifying plugin in build
section of pom.xml
without configuring execution
does not cause maven to trigger plugin execution during build lifecycle, the exception is default plugin bindings in maven distro, when maven
itself assigns particular plugins and their goals to build lifecycle.
Basically, you need to specify what goal of maven-javadoc-plugin
is required to execute during build lifecycle, typical configuration would be following:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.2</version>
<executions>
<execution>
<id>attach_docs</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
<tags>
...
</tags>
</plugin>
Upvotes: 0