Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update and add KDoc for DGPv2 #3842

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

adam-enko
Copy link
Member

@adam-enko adam-enko added this to the Dokka 2.0.0 milestone Oct 2, 2024
@adam-enko adam-enko added the runner: Gradle plugin An issue/PR related to Dokka's Gradle plugin label Oct 2, 2024
@adam-enko adam-enko marked this pull request as ready for review October 2, 2024 14:58
@adam-enko adam-enko requested a review from whyoleg October 2, 2024 14:58
Copy link
Collaborator

@whyoleg whyoleg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, mostly minor remarks

abstract val moduleVersion: Property<String>

/**
* A distinct relative path for the Dokka Module produced by the current project.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure I understand what this property could be used for when reading KDoc :(

@@ -83,32 +104,9 @@ constructor(
)

/**
* Dokka Source Sets describe the source code that should be included in a Dokka Publication.
* Dokka Source Sets describe the source code that should be included in the generated output.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dokka Source Set not only represents the source code, but also its Dokka configuration. I would say, for end-users configuration part is more important in DSL

@@ -153,6 +148,9 @@ constructor(
* }
* ```
*
* _Aside: Launching [without isolation][WorkerExecutor.noIsolation] is not an option, because
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure it's needed here, as it's not actionable (e.g why I need to know this, why it's required, what is it, etc)
probably we can safely remove this part

*
* _Aside: Launching [without isolation][WorkerExecutor.noIsolation] is not an option, because
* running Dokka Generator **requires** an isolated classpath._
* - a new process, using [ProcessIsolation],
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor: probably it's better to write here WHY someone needs to change this. E.g as in example, regarding memory usage.

* ```
*
* @see url
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure why @see is needed here, isn't it will redirect to itself?

*
* Note: You can cache files locally and provide them to Dokka as local paths.
* See [DokkaSourceSetSpec.externalDocumentationLinks].
*/
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

would be nice to add default values in docs for all properties

*
* This is an internal Dokka Gradle plugin property.
* If you find you need to set this property, please report your use-case https://kotl.in/dokka-issues.
*/
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's add @DokkaInternalApi?

@@ -23,7 +23,7 @@ import kotlin.annotation.AnnotationTarget.*
* [the Dokka issue tracker](https://github.com/Kotlin/dokka/issues).
*/
@RequiresOptIn(
message = "Internal Dokka API - may change at any time without notice",
message = "Internal Dokka Gradle API - may change at any time without notice",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BTW, may be it makes sense to rename it to @InternalDokkaGradlePluginApi?

  • to emphasise that it's related to Gradle Plugin
  • to use naming convention which is used in most libraries I saw:
    • @ Severity Domain Api?
      • SEVERITY = e.g experimental or internal
      • DOMAIN = based on library name

// return Result.failure(ex)
// }
// }
// When the minimum supported Java version is 11+
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

never? :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
runner: Gradle plugin An issue/PR related to Dokka's Gradle plugin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants