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

Do not generate source links for synthetic elements #2547

Merged
merged 1 commit into from Jun 30, 2022

Conversation

IgnatBeresnev
Copy link
Member

Fixes #2544

@IgnatBeresnev IgnatBeresnev force-pushed the 2544-java-source-linking branch 2 times, most recently from 7511939 to 0f95b13 Compare June 23, 2022 10:46
context.plugin<DokkaBase>().querySingle { commentsToContentConverter },
context.plugin<DokkaBase>().querySingle { signatureProvider },
context.logger
)

override fun invoke(input: RootPageNode) =
input.transformContentPagesTree { node ->
override fun invoke(input: RootPageNode): RootPageNode {
Copy link
Member Author

Choose a reason for hiding this comment

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

A bit of refactoring to make it not run if sources are not configured and to not parse configuration on every documentable

@@ -85,7 +85,7 @@ abstract class AbstractTest<M : TestMethods, T : TestBuilder<M>, D : DokkaTestGe
}.toSet(),
sourceLinks = sourceSet.sourceLinks.map { link ->
link.copy(
localDirectory = testDirPath.toFile().resolve(link.localDirectory).canonicalPath
localDirectory = testDirPath.toFile().resolve(link.localDirectory).absolutePath
Copy link
Member Author

Choose a reason for hiding this comment

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

The problem with paths was here. canonicalPath resolves symlinks, while absolutePath does not, so on windows it resulted in two different temp folder locations.

I'll refactor this bit later on in a separate PR once I get a hold of a windows machine

@IgnatBeresnev IgnatBeresnev merged commit 76334ec into master Jun 30, 2022
@IgnatBeresnev IgnatBeresnev deleted the 2544-java-source-linking branch June 30, 2022 14:02
IgnatBeresnev added a commit that referenced this pull request Jul 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Regression: linking Java sources broken in 1.7.0
2 participants