I know I can run the ktfmt jar to format code, but can I run it on CI as a "test" to see if code was already formatted correctly? Essentially, if ktfmt has to make a change -- then it fails.
g
gammax
05/08/2021, 6:06 AM
Nope you can't with the Jar. There is a open issue for that IIRC. But the Gradle plugin ha support for that use case
Nice. Yeah my use case is that I want a github action to check if formatting does not pass. Doing this gradle works fine but by the time we download gradle and everything it takes about 3 minutes as a github action. I was hoping I could run the jar and within seconds I would know if there was a failure. I will 👍 that issue when I'm not on mobile. Lol