diffplug / spotless

Keep your code spotless
Apache License 2.0
4.46k stars 449 forks source link

ktlint's multiline-if-else rule not fixed automatically #1264

Open andre-krueger opened 2 years ago

andre-krueger commented 2 years ago

See this ktlint issue for further information.

FAILURE: Build failed with an exception.

BUILD FAILED in 4s 2 actionable tasks: 1 executed, 1 up-to-date

nedtwigg commented 2 years ago

I believe this a ktlint limitation, not Spotless. See this comment about yellers vs solvers - there are some things that ktlint yells about but can't solve, this might be one of those.

andre-krueger commented 2 years ago

When running the ktlint binary with the format flag, it can fix it though.

nedtwigg commented 2 years ago

Thanks, that's good to know! Maybe we are somehow not calling ktlint correctly. Reopening!