is there a good example out there of a multi-modul...
# dokka
z
is there a good example out there of a multi-module project using dokka that publishes to github pages? I must confess I've been frustrated today trying to figure out how to do this and surprised that all the dokka examples seem to only write docs to their ephemeral build directories
c
I don't have the answer for GitHub Pages, but I do have the answer for GitLab pages. I assume it's similar. First, create a CI job that builds the documentation and stores the results. Then, just depend on it when you generate your Pages.
h
Or do you need versioned api docs?
g
I'm using https://github.com/ajoberstar/gradle-git-publish to copy the documentation from build/ to another dedicated repository, but I think you can target an orphan branch if you prefer to keep your documentation on the same repo. (I can't share private repositories but the setup is simple enough.)
z
Got it figured out finally but it wasn't super clear that I needed to run a separate multiModule task from the root project for it to work. Up and running now 👍
v
Also, Dokka examples (including dokka-multimodule-example) are published to GithubPages: https://kotlin.github.io/dokka/examples/dokka-multimodule-example/htmlMultiModule/ So you can have a look at our GitHub action script here
👀 1