Open skvithalani opened 6 years ago
Hey @skvithalani , I hope all is well. I'm wondering, did this ever work for you? I have a similar issue, where I don't want certain packages in a sbt unidoc.
Hello @nachmikott, for packages to be excluded from scala, we make all the members in that package private/package private. If none of the members are visible to outer world then sbt-unidoc does not include that package in scaladoc.
So, if we don't have any visible members, we don't need scaladoc for it. That's the approach.
Hello all, I didnt want to start a new ticket for this, because I think it's related. My question:
Is it possible to exclude documentation of generated sources? I mean the ones generated with Compile / sourceGenerators
?
Even though this question applies generally (e.g. for the generated parsers, etc.) - in my specific case, I have zipped source code of some external library, because it's not published anywhere. I dont want to include/generate the documentation of this external source.
Example part of my build.sbt:
lazy val myproject = project
.settings(
Compile / sourceGenerators += unzipMyLibraryTask,
...
)
lazy val root = (project in file("."))
.enablePlugins(ScalaUnidocPlugin)
.aggregate(myproject)
.settings(
ScalaUnidoc / unidoc / scalacOptions ++= Seq("-skip-packages", "com.mylibrary") // this is what I tried, but doesnt work..
)
If there is no other option, I would include it, but the problem is the library source code is not perfectly written and so the unidoc shows errors and refuses to continue. I really don't want to spend any time of fixing the library.
Thanks for any advice!
We want to exclude a particular package named "internal" from scaladoc and javadoc for all projects. We have UnidocSite plugin as follows:
But somehow "internal" package gets excluded only from javadoc and not from scaladoc.
Is there something we are missing ?