Skip to content

Conversation

@0marperez
Copy link
Contributor

Issue #, if available:

Description of changes:

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@lauzadis lauzadis marked this pull request as ready for review June 26, 2024 14:50
classpath = execKtlintClasspath
mainClass.set("com.pinterest.ktlint.Main")
args = lintPaths
jvmArgs("--add-opens", "java.base/java.lang=ALL-UNNAMED")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

question: why remove the jvm args just for ktlint?

Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I would lean towards keeping it since we don't know if it was necessary but I don't feel strongly about it. A good way to test this would be to run ktlint twice, once with and once without

Copy link
Member

Choose a reason for hiding this comment

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

Sorry, just saw this comment after I already merged the PR. I had already tested with and without the jvmArgs locally, there was no difference. In general I think we should trust our dependencies' onboarding guides and if they end up being incorrect, send them a PR to fix the documentation.

mainClass.set("com.pinterest.ktlint.Main")
args = listOf("-F") + lintPaths
jvmArgs("--add-opens", "java.base/java.lang=ALL-UNNAMED")
jvmArgs("--add-opens=java.base/java.lang=ALL-UNNAMED")
Copy link
Contributor Author

Choose a reason for hiding this comment

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

nit/style: the same change could be made in CodeStyle.kt

@lauzadis lauzadis merged commit ee2f930 into main Jun 26, 2024
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.

2 participants