Closed Bananeweizen closed 2 months ago
Thanks for pointing this out @Bananeweizen ! Linking a few quick resources for context:
The wrapperDistribution option description here contains newlines: https://github.com/openrewrite/rewrite/blob/0324a3c60ac969bc00bce8b637021cb32248e82f/rewrite-maven/src/main/java/org/openrewrite/maven/UpdateMavenWrapper.java#L73-L84
This description is converted into a table cell in our recipe-markdown-generator: https://github.com/openrewrite/rewrite-recipe-markdown-generator/blob/50dac395a6af654ca8ab752700d39f06c51820f8/src/main/kotlin/org/openrewrite/RecipeMarkdownGenerator.kt#L814-L860
The markdown that generates is eventually pushed to https://github.com/openrewrite/rewrite-docs
In the above shown snippet we already have special handling for example values that contain newlines through .replace("\n", "<br />")
. I think we could do the same here for option descriptions that contain newlines.
/cc @mike-solomon
Fixed this in this commit - please note that the docs won't be fixed until the next time we generate them (should be in the next day or two). Thanks again for pointing this out!
What is the smallest, simplest way to reproduce the problem?
Look at https://docs.openrewrite.org/recipes/maven/updatemavenwrapper
The generated table is broken, except for the first line:![grafik](https://github.com/openrewrite/rewrite/assets/406876/f383a940-e4ce-430e-9625-192099f7dea3)
Are you interested in contributing a fix to OpenRewrite?
I'm not aware how the documentation generation could be tested locally, so probably not.