I have a minigame that depends on a minigame engine, I am relocating the minigame engine in a sub package of the minigame called engine and also relocating the API part of the engine inside the minigame API. This part works flawlessly, but I want to make java docs that works the same way. I've tried maven-javadoc-plugin and that part works but it has no shading/relocating ability from what I could see, so I'm asking, is there a way to shade and relocate javadocs?
Asked
Active
Viewed 21 times
1
-
Generally you wouldn't distribute javadocs with a packaged jarfile, but either through a web server or as a separate artifact. Why do you want this? – Rogue Aug 10 '23 at 13:00
-
The end result is to post it on a website like any other javadocs I see – Fr33styler Aug 10 '23 at 13:03
-
Right. What most people do there is simply take the generated folder/"jar" (A `.jar` is a `.zip` file, and javadoc jars just contain the .html/etc), place it on a server, and point their webserver (apache/nginx/etc) at the root directory of the generated files. That's it really, the javadoc tool generates working webpages. – Rogue Aug 10 '23 at 13:07
-
Hmm, but how would that include the relocations? – Fr33styler Aug 10 '23 at 13:15
-
When you say "relocations", what do _you_ mean? Are you concerned about links? What doesn't work "the same way" in one situation vs. another? I can guess at the meaning of things, but I think maybe the question could use a few more details so I'm not shooting in the dark. Pretend I'm dumb and really spell it out, sometimes the detail helps answer your own question a bit. – Rogue Aug 10 '23 at 13:19
-
What I mean with relocations are the ones generated by the maven shade plugin, links wouldn't work properly in my task as it would show the library as unaltered. – Fr33styler Aug 10 '23 at 13:26
-
Mind you, until you've installed a new artifact (whether web-based javadocs or a maven repo artifact) then what you've linked against won't update. Regarding the javadoc plugin, there's [setting up external links](https://maven.apache.org/plugins/maven-javadoc-plugin/examples/links-configuration.html) to javadoc repos. If you automate the deployment of the javadocs to the webserver (say on maven deploy), then it'd update the javadocs when you run it. – Rogue Aug 10 '23 at 14:20
-
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. – Community Aug 10 '23 at 14:23