Hi everyone! How do I suppress only a few files fr...
# dokka
r
Hi everyone! How do I suppress only a few files from getting documented? For example: I have a package
com.ruben.api
and it has 2 files
BrowseApi.kt
and
BrowseApiImpl.kt
. I do not want to generate any documentation for the
BrowseApiImpl.kt
file. I have tried using
suppressedFiles
but it did not work. Here is my configuration:
Copy code
tasks.withType<DokkaTask>().configureEach {
    dokkaSourceSets {
        named("commonMain") {
            moduleName.set("ABC")
            includes.from("api.md")
            sourceRoots.from(file("src/commonMain"))
            skipEmptyPackages.set(true)
            documentedVisibilities.set(
                setOf(DokkaConfiguration.Visibility.PUBLIC, DokkaConfiguration.Visibility.INTERNAL)
            )
            suppressedFiles.from(
                file("src/commonMain/browse/BrowseApiImpl.kt")
            )

            sourceLink {
                localDirectory.set(file("src/commonMain/kotlin"))
                remoteUrl.set(
                    URL("GITHUB URL")
                )
                remoteLineSuffix.set("#L")
            }
        }
    }
}
Anyone who comes across this - • Use @suppress annotation to not generate documentation • I found it from this comment