Generate Javadoc HTML using maven?
Asked Answered
P

2

67

Right now I am using the maven-javadoc-plugin to attach the Javadoc to .jar artifacts when I am doing a release.

However, how can I generate the Javadoc in an html format so we can scp it to a remote server for reference?

Thanks!

Poppycock answered 2/4, 2012 at 5:18 Comment(0)
P
94

Using the same plugin, you can generate javadoc in a folder using

mvn javadoc:javadoc

It puts the help content under target/site/apidocs

You can change the output folder by using the plugin configuration parameter reportOutputDirectory

Please refer to:

Paid answered 2/4, 2012 at 5:26 Comment(1)
What if I want to generate the javadocs when i execute clean install command. I am currently trying that, but the java docs are not getting generated on Clean install. I am using <id>javadoc:javadoc</id> <phase>package</phase>Connect
N
16

if you are interested in just doing it raw, you could use the following command.

javadoc -d C:/javadoc/test com.mypackage
Nationalist answered 15/4, 2014 at 10:10 Comment(2)
you are right, somethings are so easy and maven make us believe that everything is so complex tha twe need maven in situations that are quite trivial!Comedietta
y'all need to use ant for a a half-complex build process, then tell me maven's vile. maven is a life-saver and i, for one, welcome my xml-based overlordsMelentha

© 2022 - 2024 — McMap. All rights reserved.