I recently upgraded to ktlint 1.0.1 and now I have...
# ktlint
c
I recently upgraded to ktlint 1.0.1 and now I have the following changes (in the picture) which I am not a fan of. I believe its the multiline expression rule being promoted from experimental to standard which is causing it. I have added ktlint_standard_multiline-expression-wrapping = disabled to my editor config but I’m having no luck, it keeps formatting it the same way. What could I be missing here? 🤔
In fact the above works but the gradle plugin I use doesnt seem to track changes to editor config which makes testing rule changes a nightmare
p
Please try to save
.editorconfig
changes explicitly before running ktlint again. I am not sure whether that helps with gradle plugin, but it does help me always with Ktlint CLI.
w
I think there is a new api in ktkint that can be used to query which editorconfig files ktlint detects. Thats on my list of things to look into to get ktlint-gradle to wire up the editorconfig as a task input